As a follow up to my previous post on Drupal 6 Post Migration Data Clean Up, I thought that a follow up for Drupal 7 would be useful. In this one I have also included the block_custom table for custom blocks, which seems to be a place I have overlooked before.
UPDATE `field_data_body` SET `body_value` = REPLACE(`body_value`, "http://[temporary site]", "http://[new URL]");
UPDATE `field_revision_body` SET `body_value` = REPLACE(`body_value`, "http://[temporary site]", "http://[new URL]");
UPDATE `block_custom` SET `body` = REPLACE(`body`, "http://[temporary site]", "http://[new URL]");
UPDATE `field_data_body` SET `body_value` = REPLACE(`body_value`, "sites/[temporary site]", "sites/[new URL]");
UPDATE `field_revision_body` SET `body_value` = REPLACE(`body_value`, "sites/[temporary site]", "sites/[new URL]");
UPDATE `block_custom` SET `body` = REPLACE(`body`, "sites/[temporary site]", "sites/[new URL]");
Another useful place if you are looking for post migration is to rebuild your sitemap (using xml_sitemap) and clear all the caches.
Hope it helps and Happy Drupalling.
Connect on LinkedIn. Follow me on Twitter. Grab the RSS Feed