After installing the latest version I'm told this table doesn't exist. However, the code to create the table seems to be commented out in the install file.

Comments

vacilando’s picture

Priority: Normal » Critical

Did you run /update.php after installing the new version? The necessary code is not commented out, just an old version of it. Let me know. Thanks.

vacilando’s picture

Status: Active » Fixed

Thanks for reporting the problem! Now solved -- get 6.x-2.2 and run /update.php

dan.crouthamel’s picture

Still having a problem, but that's because I tack on drupal_ in front of the database name. Shouldn't the following,

db_query("select qid,state from brilliant_gallery_checklist ".

be

db_query("select qid,state from {brilliant_gallery_checklist} " ?

jweberg’s picture

I am also having this issue. Subscribe.

queria’s picture

hi, i dont think this is fixed!
i know drupal only for a few days and today i tried this module, and i met this error also ...
i looked at *.module file and there is code mentioned above ("select ...") and there is no "prefix" part which i use for my tables (table 'drupal_brilliant_gallery_checklist' exists in my DB) ... other modules have some variable placed instead of table name - like {node} etc ...

is this the problem? or will drupal replace table name when executing this query?

iktar’s picture

Have this bug after updating drupal and gallery to the last version, the updates were successfull. I have prefix 'vea' in the names of the tables, and the error report looks like this:

user warning: Table 'zn_vea.brilliant_gallery_checklist' doesn't exist query: select qid,state from brilliant_gallery_checklist where nid=9999999 and qid not like 'user-%' and user=0 union select qid,state from brilliant_gallery_checklist where nid=9999999 and qid like 'user-%' and user=1 in /home/www/zn/htdocs/sites/all/modules/brilliant_gallery/brilliant_gallery.module on line 110.

Seems that it doesn't use table prefix in the query (zn_vea is the database name)

dan.crouthamel’s picture

The problem hasn't been fixed yet. Why, I don't know. Any place in the module code that tries to access brilliant_gallery_checklist needs to be changed to {brilliant_gallery_checklist}. It's a simple find and replace.

For what it's worth, I decided not to use this module. I'm using the Contemplates & Zend framework modules, and writing custom code that uses the Picasa API to pull the info I want and display the photos in a lightbox. I created a custom content type with a simple field that stores the picasa web album id - from that, I generate all the info I need.

darrellgray’s picture

StatusFileSize
new36.14 KB

I've made the changes Dan suggested - it seems to be working fine for us now. Attached file should be renamed *.module and replace the current download file for 6.x-3.0

darrellgray’s picture

Version: 6.x-2.1 » 6.x-3.0

revising version number - note: this problem seems to appear only when using a table prefix (hopefully the fix will be included in the next release)

darrellgray’s picture

Title: brilliant_gallery_checklist table doesn't exist » brilliant_gallery_checklist table doesn't exist (using table prefix)
Status: Fixed » Reviewed & tested by the community

guess I should also indicate patch available

zappi’s picture

StatusFileSize
new36.92 KB

Non of the above fixes work for me.

If I include i try

Any place in the module code that tries to access brilliant_gallery_checklist needs to be changed to {brilliant_gallery_checklist}. It's a simple find and replace.

I get a bank page when I refresh.

If I use the uploadet .module file it's the same.

What to do?

I have attached my module file. (renmmaed to .txt from .module)

The specefic error I get is
user warning: Table 'coffeeshop.brilliant_gallery_checklist' doesn't exist query: select qid from brilliant_gallery_checklist where qid like 'user-%' and state='1' in /home/e-smith/files/ibays/sbktitdk/html/coffeeshopdk/modules/brilliant_gallery/brilliant_gallery.module on line 659.

My prefix for the sql is drupal_

Like to the page is http://sandbox.ktit.dk/coffeeshopdk/?q=node/5

Any help would be much apreciated.

zappi’s picture

I am now using the old version of BG and it works perfectly :) I will upgrade to this version when it's been fixed :D BG rox. Ty.

smartmark’s picture

I replaced the brilliant_gallery.module file by the one Dan (#8) attached, ran a /update.php, and now the "Table 'mydb.brilliant_gallery_checklist' doesn't exist query: select qid,state from brilliant_gallery_checklist where ..." error disappeared.

The bug affects only those who use table prefix.

joserey’s picture

That's right. Great find! I used the same patch by Dan and works well for my installation.

landike’s picture

Yes. it's true.

I have installed drupal 6.12 with using table prefixes.
So now I have installed http://ftp.drupal.org/files/projects/brilliant_gallery-6.x-3.0.tar.gz and issue is still appear.

Please inform me (landike@gmail.com) or here if issue is fixed?
I'm interested in using of this module.

landike’s picture

$result = db_query("select qid,state from brilliant_gallery_checklist ".
" where nid=%d and qid not like 'user-%' and user=0 ".
" union ".
"select qid,state from brilliant_gallery_checklist ".
"where nid=%d and qid like 'user-%' and user=%d ", $nid, $nid, $uid

This is hardcode and prefixes is not supported HERE..

PLEASE FIX it ASAP

user warning: Table 'database.brilliant_gallery_checklist' doesn't exist query: select qid,state from brilliant_gallery_checklist where nid=9999999 and qid not like 'user-%' and user=0 union select qid,state from brilliant_gallery_checklist where nid=9999999 and qid like 'user-%' and user=1 in /****/sites/all/modules/brilliant_gallery/brilliant_gallery.module on line 110.

benkewell’s picture

having the same issue when i'm trying this module

it can be easily solved by replacing "brilliant_gallery_checklist" in all query with "{brilliant_gallery_checklist}"

and this is the official way to support database prefix in drupal query

landike’s picture

After reinstall current module I've installed it again.
No errors.
Looks like replacing "brilliant_gallery_checklist" in all query with "{brilliant_gallery_checklist}" HELPS, but need to test it all.

drpchris’s picture

Patch for v6-3.4 in http://drupal.org/node/517000

vacilando’s picture

Status: Reviewed & tested by the community » Fixed

Thanks! That patch was committed to dev today. Will be in 6.x-3.5.

Status: Fixed » Closed (fixed)
Issue tags: -table prefix, -brilliant_gallery_checklist, -Table doesn't exist

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