After transferring a site to my test site using the basic WordPress importer, I noticed that the images did come over and it loads the images from the test site, but the link when you click on the image takes you to the old site.
I found the following SQL command from:
irmsgeekwork.com
to find and replace text within a field.
In the wp_posts table I found the guid in some of the records were not updated so I did the following:
update wp_posts
set guid = replace(guid,'//jhtechservices.com/','http://192.168.2.150/');
While this worked and changed the guid field in the records that needed it, this didn’t fix the problem of the link to the old blog. I found the href with the old url in the Post_content field.
update wp_posts
set post_content = replace(post_content,'//jhtechservices.com/','http://192.168.2.150/')
This fixed the link issue.