Error happens right before the node is successfully created via watchdog.

Duplicate entry '778-0' for key 1 query: INSERT INTO content_field_referrers (vid, nid, delta) VALUES (778, 431, 0) in /sites/all/modules/cck/content.module on line 1207.

Then here's the corresponding error to go with this one

Duplicate entry '778-0' for key 1 query: INSERT INTO content_field_testimonials (vid, nid, delta) VALUES (778, 431, 0) in /sites/all/modules/cck/content.module on line 1207.

This is a new node so nothing is referencing this, and it wasn't set to be a reference to another node. 431 is the newly created nid. 778 is the vid & it is incremented by 2 on every new node creation. I have the rules module set up to save the node again because various tokens don't get set correctly, so this is a cheap trick that makes all my tokens work.

Comments

mikeytown2’s picture

yched’s picture

Status: Active » Closed (won't fix)

I've several reports about this, IIRC all were related to nodereferrer.module. Please see over there.

mikeytown2’s picture

Project: Content Construction Kit (CCK) » NodeReferrer
Version: 6.x-2.2 » 6.x-1.x-dev
Component: content.module » Code
Status: Closed (won't fix) » Active

Moving to NodeReferrer Issue Queue

avpaderno’s picture

Title: Duplicate entry '778-0' for key 1 query » Duplicate entry error when saving a node with rules.module
andypost’s picture

So where is a test case to find the bug? Is this really related to NodeReferrer module?

mikeytown2’s picture

#445084: Adjust module weight from 0 is where the action is. I found this bug in 3 modules, should be fairly easy to duplicate if you follow http://drupal.org/node/445084#comment-1531066. For this case, enable all Node Referrer Dependencies as well as it's self.

andypost’s picture

Suppose this bug fixed, try to upgrade to current Beta - Multiple fields is disabled for Node Referrer fields.

mikeytown2’s picture

nope still get it with the latest dev

Duplicate entry '902-0' for key 1 query: INSERT INTO content_field_testimonials (vid, nid, delta) VALUES (902, 435, 0) in /home/content/m/c/a/mcarper/html/sites/all/modules/cck/content.module on line 1213.

Duplicate entry '902-0' for key 1 query: INSERT INTO content_field_referrers (vid, nid, delta) VALUES (902, 435, 0) in /home/content/m/c/a/mcarper/html/sites/all/modules/cck/content.module on line 1213.
andypost’s picture

Status: Active » Postponed (maintainer needs more info)

@mikeytown2 can you provide more info? NodeReferrer is never save any data to database so it looks very strange!!!

hefox’s picture

I'm getting this error also and I'm not using Noderefferer, but I am using rules. Perhaps this is a rules bug instead?

avpaderno’s picture

Issue summary: View changes
Status: Postponed (maintainer needs more info) » Closed (outdated)

I am closing this issue, which is for a not supported Drupal version.