I got a new domain to replace an old one. There are a few dozen instances of the old domain name in some of the tables. Rather than going through each one individually and replacing it, is there a way I can just do a massive find/replace? Find every instances of "domain1.com" and replace with "domain2.com." Everywhere. In posts, in image links, in text, etc.
I saw online how to do it but only within a specific row/column. I want to do it everywhere in every table in every row.
I don’t think you can update multiple tables at once.
UPDATE table SET column = ‘new_domain’ WHERE column = ‘old_domain’
Alternatively, you can use phpMyAdmin to to a data export to a .sql file, open it in notepad, do a find/replace, then import the updated file using phpMyAdmin again.
I just did the tables individually. Thanks. I think I used this code:
UPDATE tablename SET columnname = replace(columnname,"newdomain", "olddomain");