Closed (fixed)
Project:
Drupal core
Version:
7.x-dev
Component:
comment.module
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Mar 2010 at 06:54 UTC
Updated:
1 Nov 2010 at 15:20 UTC
Jump to comment: Most recent file
Comments
Comment #1
Crell commentedSounds like someone is running a bad query on that page.
Comment #2
scottrouse commentedI'm still getting this error with a fresh install of 7.0-alpha7. When I click on Content in the admin menu, then click the Comments tab.
The website encountered an unexpected error. Please try again later.Should this be a critical bug?
Comment #3
gagarine commentedI tried with the head today and I have no more error.
Comment #4
pheudo commentedHere the same error.
Maybe could it be SQLite?
Comment #5
Crell commentedWhat configuration are you running when you get the error? Is it only on SQLite? Can you try on MySQL and see if it still breaks?
Actually, looking at the query more closely it looks like the ORDER BY clause is the culprit. Both node and comment have a "changed" column, so the DB doesn't know which one to use. It could be that MySQL is smarter about figuring it out than SQLite is. Sounds like we need a patch for that query to be explicit about which one is intended.
Comment #6
webchickI can't reproduce on MySQL. Must be a SQLite thing.
And fwiw we do have test coverage for this condition, it looks like:
Comment #7
sivaji_ganesh_jojodae commentedTested against beta and dev release with MySQL and sqlite3. I can not reproduce any error.
Comment #8
pheudo commentedI can't reproduce on MySQL too. Maybe a SQLite thing.
Comment #9
pheudo commentedIt looks some matter with the changed field because is present into the node table too...
It's really strange.
If I comment changed header it works.
If I use c.changed instead it works too...
Comment #10
Crell commentedHm. Let's try specifying c.changed in the header array and see if that fixes it. pheudo, can you roll a patch?
Comment #11
pheudo commentedBut it doesn't explain why in some installation it works and in other we got error.
Maybe the PHP version (and the OCI sqlite extension bundled)?
I'm using 5.2.9 and I tried with the latest 5.2.14.
I didn't try with 5.3...
Comment #12
sivaji_ganesh_jojodae commentedAttached is the patch replacing "changed" to "c.changed" in the header array.
Comment #13
Crell commented#12 should go in either way for cleanliness if nothing else. Let's do that and see if SQLite is fixed as a result.
Comment #14
webchickCommitted to HEAD. Thanks!