{"id":612,"date":"2012-02-20T22:53:39","date_gmt":"2012-02-21T05:53:39","guid":{"rendered":"http:\/\/www.52techtips.com\/blog\/?p=612"},"modified":"2012-02-20T23:02:10","modified_gmt":"2012-02-21T06:02:10","slug":"mysql-find-and-replace","status":"publish","type":"post","link":"https:\/\/52techtips.com\/blog\/2012\/02\/20\/mysql-find-and-replace\/","title":{"rendered":"MySQL find and replace"},"content":{"rendered":"<p>Recently, I have been helping a friend with his new website using WordPress. We initially set up the site under one of his existing domains prior to purchasing a dedicated domain name for the site we were developing. He actually posted a lot of content prior to getting the new domain so when it came time to make the move, it was clearly necessary to perform a &#8220;find and replace&#8221; on the MySQL database to update the URL on all of the posts he had created.<\/p>\n<p>After a little google searching I found this site &#8211;\u00a0<a href=\"http:\/\/wordcastnet.com\/2010\/how-to-find-search-replace-and-delete-within-your-wordpress-mysql-database\/\" target=\"_blank\">http:\/\/wordcastnet.com\/2010\/how-to-find-search-replace-and-delete-within-your-wordpress-mysql-database\/<\/a><\/p>\n<p>Everything I needed was explained. What a relief. After a few minutes of backing up and trial and error, I was able to run the query and update over 70 posts. I want to keep this query handy for the future. I&#8217;m pretty sure there will be a time when it is needed again and most likely for far more.<\/p>\n<p>[wp_ad_camp_1]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Recently, I have been helping a friend with his new website using WordPress. We initially set up the site under one of his existing domains prior to purchasing a dedicated domain name&#8230;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[58],"tags":[40,50],"class_list":["post-612","post","type-post","status-publish","format-standard","hentry","category-technology","tag-database","tag-mysql"],"_links":{"self":[{"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/posts\/612","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/comments?post=612"}],"version-history":[{"count":2,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/posts\/612\/revisions"}],"predecessor-version":[{"id":615,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/posts\/612\/revisions\/615"}],"wp:attachment":[{"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/media?parent=612"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/categories?post=612"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/52techtips.com\/blog\/wp-json\/wp\/v2\/tags?post=612"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}