Some nodes are showing a 404 status when they exist in the database. You also get a 404 if you type in the url to edit that node in the admin page.
These nodes are being created in an automated fashion in the database, from CSV files. What I’d like to ask is which db fields would trigger a 404 on a node?
I have checked the url_alias table, and the nodes have valid entries. ie: If I enter example.com/node/512682 in the URL, it will do a redirect to the SEF url, but that would show a 404
Does your ‘code creation from CSV’ automation also creates entries in the ‘node_revisions’ table? If it doesn’t, this would explain the 404s – even if you have disabled revisions for a node type, Drupal will still expect at least one entry per node there.
You can create those on your import as well, but I agree with Scott Reynen (+1) that you should probably use
node_save()to ensure proper processing of newly created nodes (especially invocation of the related hooks) to prevent other surprises as well.