Would it be possible to do a little more 'advanced' string replacing in a MySQL query? I read about the REPLACE()
method, but as far as I know, it cannot be used for fancy stuff.
Basically, what I'm trying to do is remove all HTML tags from a specific column in a large dataset. Being able to do this in a single query would be a lot cooler than having to use PHP to do the processing in between. Can I do something elegant in order to remove everything encapsulated in < >
?
I just realized there's another small catch to it... due to some improper data conversions before, some of the tags now contain < and > themselves... Worst cases look like <(><<)>b>
. Don't even ask how, but something seems to have gone terribly wrong. Anyhow, great minds with great ideas on this?