By bryanpflug on
I recently uploaded a large (>500) number of nodes to my 4.4 site via SQL. I used SQL rather than node_import because I needed to be able to assign taxonomy verbs to each node during the import process. I'm not yet ready to tackle something like patching node_import, until I better understand the data structures of the site content.
All the new data displays just fine. However, when I try to create a new node via the 'create content' link, I get an error that the node id already exists. There must be some place where the next node number value should be reset. Can someone perhaps offer a hint of how to do that?
Thanks!
Comments
Node Counter
I'm not much help, but hopefully this will point you in the right direction. Drupal has a counter in the database for nodes. Codemonkeyx references it here where he says:
Since I'm not 100% sure if this will work or not, please back things up before changing anything by hand.
That counter can be found in
That counter can be found in the 'sequences' table.
--
Drupal services
My Drupal services
Thanks!
I'll remember that for future reference.
Had to increment it manually
I did something similar recently, when I wrote custom scripts to import data from an old custom made CMS to Drupal.
You have to do:
select max(nid) from node;
Then take that result
update sequences set id = 'num' where name = 'node_nid';
Where num is the result from the first SQL statement.
--
Drupal performance tuning and optimization, hosting, development, and consulting: 2bits.com, Inc. and Twitter at: @2bits
Personal blog: Ba