PHP's strip tags() equivalent in MYSQL?



Hi All,

Do we have Mysql equivalent function of PHP strip_tags? I have a field in my mysql table that has html in it. I want to strip tags when doing select.. just like PHP strip_tags()?

Any ideas?



I don't think we have any such function similar to php strip_tags() in mysql. You would have to do your select and then strip_tags() in your php code.

Try this REPLACE(description, REGEXP '(<[a-zA-Z][^>]>)','')