MyBB Community Forums

Full Version: sql query
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

I want to run a sql update so that wherever my xzy.com is placed to be replaced with my new abc.com, what do i need to run in sql query to make the changes?

Update : i have solved it myself.
Edit: Delayed response. Not seen that it is already resolved.

you can try it like this
UPDATE `mybb_posts` SET `message` = REPLACE(message, 'olddomain.com', 'newdomain.com') WHERE `message` LIKE '%olddomain.com%'; 

see also this guidance (if required) => Common SQL queries and how to run them