Problem: Help! I need to replace some words with something else in my database.
Solution: Use the replace() function to do a search and replace query.
UPDATE table_name SET
table_field=REPLACE(table_field,"old_text","new_text");
Here’s an example:
UPDATE wp_posts SET
post_content=REPLACE(post_content,"localhost","www.cybervaldez.com");
Easy as pie!
Some links that you might find useful [External]:Still can't see what you're looking for?









