AFAIK there's nothing built in. You could build a SQL function I'm sure, but personally I would just store 2 versions of the content, one with tags and one without. For me the greater disk usage would be preferable to running some complex function with every query.
criterion9, yes, it's work not so fast, but author of the topic didn't ask about fast solution and why did you decide that he going to run this query very often. Maybe he going to run it under admin panel sometimes?