Closed (fixed)
Project:
XML sitemap
Version:
6.x-1.x-dev
Component:
xmlsitemap_node.module
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
15 Jun 2008 at 12:39 UTC
Updated:
13 May 2009 at 19:40 UTC
Using "Attached Images", on Browsing and selecting an image to upload, on pressing Submit, I get a warning message that mentions xmlsitemap_node:
user warning: Duplicate entry '2463' for key 1 query: INSERT INTO xmlsitemap_node (nid, pid, last_changed, priority_override) SELECT 2463, ua.pid, 1213532785, NULL FROM node n LEFT JOIN url_alias ua ON ua.src = CONCAT('node/', CAST(2463 AS CHAR)) LIMIT 1 in /home/752/../public_html/includes/database.mysql.inc on line 172.
My thumbnail and image both seem to have uploaded fine, so I don't know whether this message is serious.
Comments
Comment #1
avpadernoIt just means that XML Sitemap is trying to insert in its table a value that is already present. It's not critical, but it's surely a serious bug.
Comment #2
avpadernoI am changing the referring version.
Comment #3
mikeytown2 commentedError showed up in the 6.x version
Error happens right before the node is successfully created via watchdog.
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. FYI Error appears only in 3 modules out of about 80 modules.
#444947: Duplicate entry error
#445034: Duplicate entry error when saving a node with rules.module
Comment #4
avpadernoI guess it depends on the method used from Rules to save the node.
xmlsitemap_node.module implements
hook_nodeapi(), and when the operation is update it first checks if a database row already exists; it doesn't check that when the operation is insert, which is supposed to be invoked when a node is being inserted in the database, not when the node data are being updated in the database.It seems more a issue with Rules, rather then with the modules you have opened an issue for.
Comment #5
avpadernoI am changing the title to something more appropriate; as the error doesn't appear in all cases, but just when saving a node through Rules, I am making the title more descriptive.
Comment #6
avpadernoAs I reported in http://drupal.org/node/445084#comment-1529778, I am not able to reproduce this issue in the test site I am using.
Comment #7
andypostSo maybe this issue is related to Rules?
Comment #8
avpadernoIf it would be an issue with this project, the problem would not appear only when saving again the node with Rules.
Comment #9
avpadernoAs I thought, the module causing the issue was Rules. The issue is being fixed in that module.
Comment #10
mikeytown2 commentedthanks for helping out in all the threads I made :)