I have converted a site over to wordpress recently. I was able to import all the posts via a CSV importer, but not the images associated with each post. The post type is "machinery". The custom field with the post's previous ID on the old system of each post is called "machinery_legacy_idLocation". I have an additional table called "legacy_images".
"legacy_images" has 2 columns "ListingID" and "imageurl".
"ListingID" in the "legacy_images" table matches a post with the same "machinery_legacy_idLocation".
Now the "imageurl" matches the title of a corresponding image that I have already added to the media library in Wordpress.
Basically I just need to figure out a way to reattach all these images to all these posts after the move.