Visiting a Nodequeue View I get following error!

user warning: Table 'mydb.smartqueue' doesn't exist query: SELECT qid, use_parents FROM smartqueue WHERE qid IN (1) in /…/modules/nodequeue/smartqueue.module on line 158.

Shall I revert to the older version?

Comments

bohz’s picture

Same error here.
the error is displayed on views as well as on nodequeue administration pages, even though smartqueues seem to be populated correctly.
and there is not a "smartqueue" table in my db (even after running update.php a couple of times)

[EDIT: trying to enable the "Assume parent term for hierarchical vocabs" settings fires 3 more errors like this and the setting is not saved]

Thanks!

ccoppen’s picture

Same error here on fresh install.

ezra-g’s picture

Priority: Critical » Normal

Looks like the smartqueue .install never made it into CVS from #358861: Assume parent terms in hierarchical vocabs for taxonomy smartqueues. I'll address this today. In the meantime, is there a reason this is critical?

ezra-g’s picture

Status: Active » Fixed

A new release will be available in the next 5 minutes. Sorry about the errors!

jim kirkpatrick’s picture

Version: 6.x-2.6 » 6.x-2.7
Status: Fixed » Active

The latest (2.7) does not directly fix this error, still getting complaints about missing smartqueue table.

I had to disable the "Smartqueue taxonomy" module, un-install it, then enable it again to get rid of the message.

Perhaps this update/install file is still broken, or the release notes need updating with more instructions? Or is there a specific DB update we should choose when running update.php?

ezra-g’s picture

Status: Active » Postponed (maintainer needs more info)

Did you run update.php after installing the 6.x-2.7 release? The update required is smartqueue_6001, and it should run automatically.

jim kirkpatrick’s picture

@erza-g: I did run update.php. However, after that update the update status page (at end of update process) had a Drupal error saying the table 'smartqueue' was missing. Sorry, should have mentioned that before!

Note also I went straight from 2.5 to 2.7, in case that is relevant.

jim kirkpatrick’s picture

Status: Fixed » Postponed (maintainer needs more info)

Just ran the update on another copy of my site and, in addition to the SQL table missing error I mentioned above, the status page of the update script says:

The following queries were executed

nodequeue module
Update #6005
* UPDATE {system} set name = 'nodequeue_view_per_queue' where name = 'nodequeue_automatic_views_generation'

smartqueue module
Update #6001
* No queries

And at the top of the screen I have "user warning: Table 'mydb.smartqueue' doesn't exist query: INSERT INTO smartqueue (qid) SELECT qid FROM nodequeue_queue in /.../www/sites/all/modules/nodequeue/smartqueue.install on line 37."

ccoppen’s picture

I got the update error after the update screen too, but haven't seen it since. I think it was just a leftover.

ezra-g’s picture

Status: Postponed (maintainer needs more info) » Active

I think users who already have smartqueue installed will have these errors, because despite being in the schema, there is no function that adds the new table for existing users. I missed this when reviewing the patch but hope to produce a fix shortly.

ezra-g’s picture

Status: Active » Fixed

A new release will be available in 5 minutes. I apologize for the inconvenience.

bohz’s picture

Thanks Ezra,
I updated from 2.6 to 2.8 and got this erroe on updat.php:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') /*!40100 DEFAULT CHARACTER SET UTF8 */' at line 2 query: CREATE TABLE smartqueue ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in */public_html/includes/database.inc  on line 550.

The "smartqueue" table was not created

Is there something wrong with my db?
Thanks

ezra-g’s picture

Status: Fixed » Postponed (maintainer needs more info)

Yikes. "It works for me." Are you ran smartqueue update 6002 and that the table doesn't exist in your database?

bohz’s picture

exactly.
what should I do?
uninstall/reinstall nodequeue? which version?
TIA

ezra-g’s picture

You could try disabling *and then uninstalling from the uninstall menu* just smartqueue.module, and then re-enabling.

ccoppen’s picture

it worked for me this time. no problems....thanks for the quick work today, ezra

bohz’s picture

Status: Postponed (maintainer needs more info) » Fixed

uninstalling and reinstalling smartqueue taxonomy did work well.
I didn't even lose any data: my smartqueues returned back as before.
Adding my voice to thank you for the quick fix of today.
Cheers

AntiNSA’s picture

Status: Postponed (maintainer needs more info) » Fixed

I recieved these errors when upgrading:

warning: Invalid argument supplied for foreach() in /home/cyberfan/htdocs/includes/database.mysql-common.inc on line 69.
user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') /*!40100 DEFAULT CHARACTER SET UTF8 */' at line 2 query: CREATE TABLE smartqueue ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in /home/cyberfan/htdocs/includes/database.inc on line 550.
user warning: Table 'cyberfan.smartqueue' doesn't exist query: INSERT INTO smartqueue (qid) SELECT qid FROM nodequeue_queue in /home/cyberfan/htdocs/sites/all/modules/nodequeue/smartqueue.install on line 39.

luti’s picture

I've had the same problem as #12 & #18 at upgrade 2.6 -> 2.8.

#15 seems to do the job, but I don't feel comfortable doing such things.

Looking at the smartqueue.install, why is not simply drupal_install_schema() used within smartqueue_update_6002() too? Since smartqueue_install() seems to work, while smartqueue_update() doesn't - and, it seems both should do more or less the same...

Generally - noticing versions to grow within a couple of days from 2.5 to 2.8 (in which a bug popped out at update already...) - I would also suggest to publish "final" versions with a bit more care. Why not use more user friendly system with betas and release candidates (which can eventually convert into final releases in case no bug reports...)? For a production site, it is really not a nice feeling for a webmaster to rely on modules which change almost every day... If I would know that those new releases are so stable, I would wait (and not update immediately) for sure. Also plenty of Coder complains (altough mainly insignificant ones...) doesn't look nice.

I appreciate the code you are providing to us, thank you very much. But, take your time, guys, and publish as final only more widely tested code, please. This way, I will appreciate your module (and, consequently your work) even more.

gaele’s picture

Version: 6.x-2.7 » 6.x-2.8
Status: Fixed » Active

Hi ezra-g, this is what update.php reports after updating from 2.5 to 2.8:

The following queries were executed
nodequeue module
Update #6005

* UPDATE {system} set name = 'nodequeue_view_per_queue' where name = 'nodequeue_automatic_views_generation'

smartqueue module
Update #6002

* Failed: CREATE TABLE {smartqueue} ) /*!40100 DEFAULT CHARACTER SET UTF8 */
* Failed: INSERT INTO {smartqueue} (qid) SELECT qid FROM {nodequeue_queue}

gaele’s picture

LUTi, please try to stay constructive.
If your site is that important to you perhaps you should use a test site.

dddave’s picture

at #21

I think this was a pretty constructive post. No ranting and providing some maybe helpful input, too.

Anyways, don't let us derail this issue. ;)

luti’s picture

Version: 6.x-2.8 » 6.x-2.7
Status: Active » Fixed

gaele,

it was meant absolutely constructively.

Maybe even more than reporting again more or less the same as already reported a couple of posts above... ;-)

Unstable releases doesn't help anyone. One can only decide to find some other alternative, if it turns out some piece of software is causing too much (or, too serious) inconveniences. So, instead of having wider user base (and, thus better tested software), it goes in the opposite way. Why would for instance version 6.x-2.6-beta1 (and, up to beta 3 up to now) be worse than 2.6 (and, up to 2.8)? We would just be warned that this software was released within a couple of days, without much testing. So, I would be warned that maybe I should test something more through (or, keep an eye on it more often, and more in depth...). I've discussed that issue may times, and I have much more respect towards to the software (and, authors) which doesn't rush with versions, but any new version they publish really means something (and, I can trust it more).

By the way, I have (practically exactly the same) test site (a couple of them, infact - for different purposes...), but believe me or not, somethimes they behave differently (if nothing else, many different clients from different environments are visiting a production site, while I can check a test site only with my clients...). So, it is not that easy... ;-)

AdrianB’s picture

Subscribing.

gaele’s picture

Version: 6.x-2.7 » 6.x-2.8
Status: Fixed » Active

Version 6.x-2.8 still contains this bug. See #20.

ezra-g’s picture

Status: Active » Needs review
StatusFileSize
new789 bytes

Does applying this patch and running update.php resolve the errors for those who are having them?

ezra-g’s picture

StatusFileSize
new787 bytes

These are virtually identical but the $ret is slightly improved. With either, the first action will report as failed but you can ignore that.

ezra-g’s picture

Status: Needs review » Needs work
ezra-g’s picture

Title: Error after latest update to 6.x-2.6 » Smartqueue table not created
Status: Needs work » Fixed
StatusFileSize
new1.4 KB

I have committed the attach patch, which (actually) fixes this problem and will roll another release shortly.

@LUTi : We don't use drupal_install_schema per http://drupal.org/node/150220 .

I appreciate your concerns about frequent updates, but before this bug/release, the last Nodequeue official release was in 2009 November ;). Also, the release that contained this bug was far more stable in other critical areas (like not deleting all of your taxonomy smartqueues in some cases) than the previous release. See the Release notes for the full list of bug fixes.

I tried to help folks out by switching gears from another (pressing) project to do a quick re-release, and the mixed results reminded why that's not a good approach, even though it pains me to let an issue like this wait in the queue a few hours so that it can get my full attention.

I think the record of stable releases with Nodequeue is excellent, and in introducing new features, I've taken a great deal of care to release stable code, even if that means delaying an awesome new feature (like #234004: Drag and drop node ordering). I'm not aware of contrib modules that are complex, widely used and, as you propose, also bug free.

AntiNSA’s picture

I just wanted to say thank you for updating nodequeue! I am so happy that you have found time to update! Nodequeue and nodequeue OG are so important.. I am sad when I have a problem, but updates are great! I wish we could have them everyday ! I could never complain about their being too many!!!!!!

What is that patch attached to your posat? Should I install that or ois it inclueded in the newest dev release?

luti’s picture

ezra-g,

don't misunderstand me, please.

I appreciate the hard work of any developer / maintainer, and thank you again for your contribution.

I would just find it more appropriate to publish for example 6.x-2.6-beta1 or so instead (or even 6.x-3.0-dev, if the new feature is important enough...), and keep the old stable version as recommended for a couple of weeks (until the new release proves not to contain serious bugs...). For a related project you are referring to, you could have a note on a project page to use a new beta (or, dev) version, if the new functionality is needed. We often see some older version as recommended for production sites, while new version(s) is in development - as for example: XML sitemap module.

For people like me, who is many times less interested for some new features, but much more for stability, this would save some time, and make me feel better (more sure everything works as expected). I really like modules which I can trust not to break my site (or, take me too much time due to frequent updates - maintaining a web site is not my primary occupation, and I simply don't have much time for such tasks just any moment...). And, exactly beause your module proved to be stable in the past, I was less careful with it (with some modules, I wait a couple of days with updates, to see about the issues / feedback first...). I would like to keep it this way, therfore my suggestion. You as maintainer have all rights to proceed as you find it better, of course.

luti’s picture

BTW,

updating to 2.9 (from 2.8) resulted in the following error:
user warning: Table 'smartqueue' already exists query: update_sql /* webmaster : update_sql */ CREATE TABLE smartqueue ( `qid` INT unsigned NOT NULL auto_increment, `use_parents` TINYINT DEFAULT 0, PRIMARY KEY (qid) ) /*!40100 DEFAULT CHARACTER SET UTF8 */ in /var/www/html/my_site/includes/database.inc on line 550.

Probably this is OK, as the table has already been there, but still - not nice to see error reports.

dddave’s picture

Error in #32 confirmed. Nothing to worry about I guess.

Status: Fixed » Closed (fixed)

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

steven jones’s picture

Version: 6.x-2.8 » 7.x-2.x-dev
Priority: Normal » Critical
Status: Closed (fixed) » Active

Smartqueue 2.9 is now broken for people who installed at 2.7 or 2.8. As per comment #32.

steven jones’s picture

Status: Active » Needs review
StatusFileSize
new2 KB

We must check to see if the table exists before just going on to create it.

This patch does just that. This needs to go in a 2.10 release ASAP, IMHO.

steven jones’s picture

StatusFileSize
new2.27 KB

Actually that is broken too, as all the queues are inserted into the smartqueue table.

We check for each queue, and add it to the smartqueue table if needed.

jordan8037310’s picture

Status: Needs review » Needs work

steven,

tried that patch, got this error

Parse error: syntax error, unexpected T_IF, expecting ')' in /sites/all/modules/contrib/nodequeue/smartqueue.install on line 47

amateescu’s picture

Status: Needs work » Fixed
StatusFileSize
new2.19 KB
new2.28 KB

Tested the patch from #37 by upgrading from 6.x-2.8 to 6.x-2.9 and it works great. I did a little adjustments and commited attached patches to 6.x and 7.x.

http://drupalcode.org/project/nodequeue.git/commit/53dad31
http://drupalcode.org/project/nodequeue.git/commit/373c36a

Status: Fixed » Closed (fixed)

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