user warning: Multiple primary key defined query: ALTER TABLE kKk_xmlsitemap_node ADD `nid` INT unsigned NOT NULL DEFAULT 0, ADD PRIMARY KEY (nid) in ./includes/database.mysql-common.inc on line 298.

Update #6100

* Failed: ALTER TABLE {xmlsitemap_node} ADD `nid` INT unsigned NOT NULL DEFAULT 0, ADD PRIMARY KEY (nid)

after cron

* user warning: Unknown column 'xn.nid' in 'where clause' query: SELECT n.* FROM dbk_node n LEFT JOIN db_xmlsitemap_node xn ON xn.nid = n.nid WHERE xn.nid IS NULL AND n.status <> 0 LIMIT 0, 200 in ./xmlsitemap/xmlsitemap_node/xmlsitemap_node.module on line 71.
* user warning: Unknown column 'xt.tid' in 'where clause' query: SELECT t.* FROM db_term_data t LEFT JOIN db_xmlsitemap_taxonomy xt ON xt.tid = t.tid WHERE xt.tid IS NULL LIMIT 0, 200 in ./xmlsitemap/xmlsitemap_taxonomy/xmlsitemap_taxonomy.module on line 26.

Comments

Anonymous’s picture

Status: Active » Postponed (maintainer needs more info)

Did you run update.php on an existing 6.x-1.N where N is either x-dev or beta[12345]? There is no and will not be an update path for the reversal of code.

See [359104-226] for the last entry on status.

eule’s picture

hmm ? i dont have installed any time a beta, i just install any new 6.x-1.x-dev! at this time (2009-Jun-11)

Anonymous’s picture

I will try to implement filters for the DB changes. Keep watching #359104: XML sitemap 6.x-1.x-dev progress for updates.

dave reid’s picture

Marked #488608: Errors in DB Patch #6100 as a duplicate of this issue.

dave reid’s picture

Marked #488782: Unknown column 'xt.tid' as a duplicate of this issue (unknown column xt.tid).

avpaderno’s picture

Drupal.org seems to not update the status of the issue link you reported here; it shows the issue as active while it's not so.

Anonymous’s picture

What version of Drupal?

What version of MySQL?

What version of PHP?

What version of Apache?

I'm having terrific success with re-executing the updates without any error. The code is already filtered and shouldn't provide you with any issue that I can find.

avpaderno’s picture

i just install any new 6.x-1.x-dev

I don't know if install is correctly used to mean a real installation rather than an update. If there would be a code error, it should be evident to earnie too, I think.
Just to be sure the error is shown when installing the module, earnie should try to uninstall / install the module (if he has not done that already).

Anonymous’s picture

earnie should try to uninstall / install the module (if he has not done that already)

Yes, something like three or more times a day.

Anonymous’s picture

Drupal.org seems to not update the status of the issue link you reported here; it shows the issue as active while it's not so.

I've seen this and the next day take a look and it is usually changed. I think it requires a cron run on drupal.org and maybe something they do not do daily.

avpaderno’s picture

Yes, something like three or more times a day.

Then, the described problem is not caused by the code, and the user is having the problem because something else.
I find not reproducible errors rather hard to be marked as bugs.

avpaderno’s picture

I've seen this and the next day take a look and it is usually changed. I think it requires a cron run on drupal.org and maybe something they do not do daily.

That could explain what I see. I noticed that to see the status of the linked issue change, I have to cancel the text I wrote in the comment, save the comment, edit the comment again, and insert again the text I add before; in that case, the issue status is changed, and the link background color is changed. I must say that is a procedure too boring to be applied all times.

Thanks for the explanation; I am sorry I polluted the issue report with something that is marginal, compared with the issue.

eule’s picture

hi
the bug has not solved for me..after cron i get again a red screen

* user warning: Unknown column 'xn.nid' in 'where clause' query: SELECT n.* FROM db_node n LEFT JOIN db_xmlsitemap_node xn ON xn.nid = n.nid WHERE xn.nid IS NULL AND n.status <> 0 LIMIT 0, 200 in ./xmlsitemap/xmlsitemap_node/xmlsitemap_node.module on line 71.
* user warning: Unknown column 'xt.tid' in 'where clause' query: SELECT t.* FROM db_term_data t LEFT JOIN db_xmlsitemap_taxonomy xt ON xt.tid = t.tid WHERE xt.tid IS NULL LIMIT 0, 200 in ./modules/xmlsitemap/xmlsitemap_taxonomy/xmlsitemap_taxonomy.module on line 26.

What version of Drupal? 6.12

What version of MySQL? 5.0.51a

What version of PHP? 5.2.6

What version of Apache? Apache/2.2.8 (Linux/SUSE)

the sitemap.xml gets(shows) only tags linked...if i join the site with IE as unregistred user i see

user warning: Unknown column 'xn.nid' in 'on clause' query: SELECT n.nid, n.vid, n.type, n.language, n.uid, n.created, n.promote, xn.changed, xn.previously_changed, xn.priority_override, xn.comment_ratio FROM db_node n INNER JOIN db_xmlsitemap_node xn ON n.nid = xn.nid WHERE n.status > 0 in ./xmlsitemap/xmlsitemap_node/xmlsitemap_node.module on line 297.
user warning: Unknown column 'xt.tid' in 'on clause' query: SELECT t.tid, t.vid, v.module, xt.changed, xt.previously_changed, xt.priority_override FROM db_term_data t LEFT JOIN db_vocabulary v ON t.vid = v.vid LEFT JOIN db_xmlsitemap_taxonomy xt ON t.tid = xt.tid in ./xmlsitemap/xmlsitemap_taxonomy/xmlsitemap_taxonomy.module on line 206.

Anonymous’s picture

If you look at the db_xmlsitemap_node table with phpmyadmin do you see a column named nid?
If you look at the db_xmlsitemap_taxonomy table with phpmyadmin do you see a column named tid?

If yes, then your MySQL version must be buggy. If no, then what date was the previous -dev version you had installed? I would need to know so that I can get it, install it and try and update.php. Otherwise, follow the instructions at #379854-128: The site map is not being populated to get your sitemap.xml working again.

Anonymous’s picture

dave reid’s picture

I don't see how that's related because I think that article refers to column aliases, aka SELECT table1.col1 AS a, table2.col1 AS b FROM table1 LEFT JOIN table2 ON a = b

Anonymous’s picture

Oh yeah, right. I missed the "column alias" clearly written in the post.

eule’s picture

hi

If you look at the db_xmlsitemap_node table with phpmyadmin do you see a column named nid? i s a field named mid
If you look at the db_xmlsitemap_taxonomy table with phpmyadmin do you see a column named tid? same field named mid

no nid, no tid

i report always from the last dev kit, i update daily this time the error comes with XML Sitemap 6.x-1.x-dev (2009-Jun-12)

i purge some pages from the start site ..this brings a error in the common.inc

# db_xmlsitemap_taxonomy SET changed = 1244825066 WHERE tid = 0 in ./includes/common.inc on line 3422.
# user warning: Unknown column 'tid' in 'field list' query: SELECT tid, changed, previously_changed, priority_override FROM db_xmlsitemap_taxonomy WHERE tid = 38 in ./xmlsitemap/xmlsitemap_taxonomy/xmlsitemap_taxonomy.module on line 101.
# user warning: Unknown column 'tid' in 'where clause' query: UPDATE db_xmlsitemap_taxonomy SET changed = 1244825066 WHERE tid = 0 in ./includes/common.inc on line 3422.

avpaderno’s picture

As far as I can remember, both the fields are present from much time; recent commits didn't remove those table fields, and the reported error should not appear. It seems that something is wrong with the specific installation of XMLsitemap, but I think it's not caused by the actually implemented code.

Anonymous’s picture

i report always from the last dev kit, i update daily this time the error comes with XML Sitemap 6.x-1.x-dev (2009-Jun-12)

I'm looking for the version you used that gave you no nid in xmlsitemap_node and not the current one you're trying to use.

That said please follow exactly the instructions at #379854-128: The site map is not being populated. If you have errors with that you'll need to remove the xmlsitemap tables from the DB manually and remove the rows from the system table WHERE name IS LIKE 'xmlsitemap%'. Make sure you removed the modules/xmlsitemap directory before extracting the -dev tarball.

eule’s picture

jo

the issues is from June 11, 2009 - 01:39 ..so must be the dev from June 11 0:38

but thanks for the tip @earnie ..i clean out my db. and reinstall this today dev 13 june 0:30 and it works for me @the moment

aeehhm

xmlsitemap 13.06.2009 - 00:46 Error occurred submitting sitemap to Yahoo!: 403
xmlsitemap 13.06.2009 - 00:46 Error occurred submitting sitemap to Windows Live: 301

avpaderno’s picture

Category: bug » support
Status: Postponed (maintainer needs more info) » Fixed

The errors you are reporting are because some temporary errors in the communication with the server in the first case, and the redirection to a different URL for the second case; they are not database errors.

As you reported that you are not having the original problem anymore, I am setting this report as fixed. What reported here was not even a bug of the code; I am changing category as well.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.