By chriscohen on
Recently I was required to import about 7000 nodes into Drupal 5. I was not entirely sure how to achieve this, but I decided to use SQL scripting.
I ran into a problem where none of the manually imported nodes were appearing in search results. Nodes created within Drupal worked fine, appearing in search results as expected. My manually imported nodes worked fine on the site itself: by nagivating to node/1234 it was possible to view the node as expected, and they worked fine with Views, but there was nothing in the search results.
I wrote some notes on the issue as a blog post, and any help or insight would be appreciated, as a reply here or comment on the blog.
Comments
This is a possible solution
This is a possible solution to the above:
I had a similar issue. Imported several thousand nodes from a non-Drupal website. Basically because they were all imported with a script the database field for "creation date" and "updated date" were the same for all 4000 nodes. To make a long story short, indexing fails to get through that many nodes if they have the same "updated date" in the database.
The Solution:
I'm not a coder or database wiz so I had to look elsewhere. Views Bulk Operations (VBO) will allow you to bulk save many nodes at a time. By re-saving the nodes they get a new updated date and the indexer works.
Install VBO, create a VBO view with a page that lists 50 nodes per page, add filters (updated date, nid, title, whatevers helpful), go to that VBO view page and start bulk re-saving nodes 50 at a time (filter by the updated date that you used for importing), run cron, repeat, rinse. I did 50 at a time just to be careful... thinking that if you do too many, you have the same problem all over again.
peace