Anaonymous visitors get this warning on most pages:

     * user warning: Unknown column 'n.type' in 'where clause' query: SELECT nid, title FROM node WHERE (( CASE n.type WHEN 'stormexpense' THEN 0 WHEN 'storminvoice' THEN 0 WHEN 'stormknowledgebase' THEN 0 WHEN 'stormnote' THEN 0 WHEN 'stormorganization' THEN 0 WHEN 'stormperson' THEN 0 WHEN 'stormproject' THEN 0 WHEN 'stormtask' THEN 0 WHEN 'stormticket' THEN 0 WHEN 'stormtimetracking' THEN 0 ELSE 1 END )=1 ) AND ( type = 'blog' AND status = 1 AND created < 1244502789 )ORDER BY created DESC LIMIT 0, 1 in [mysite]/themes/plainscape/template.php on line 231.
     * user warning: Unknown column 'n.type' in 'where clause' query: SELECT nid, title FROM node WHERE (( CASE n.type WHEN 'stormexpense' THEN 0 WHEN 'storminvoice' THEN 0 WHEN 'stormknowledgebase' THEN 0 WHEN 'stormnote' THEN 0 WHEN 'stormorganization' THEN 0 WHEN 'stormperson' THEN 0 WHEN 'stormproject' THEN 0 WHEN 'stormtask' THEN 0 WHEN 'stormticket' THEN 0 WHEN 'stormtimetracking' THEN 0 ELSE 1 END )=1 ) AND ( type = 'blog' AND status = 1 AND created > 1244502789 )ORDER BY created ASC LIMIT 0, 1 in [mysite]/themes/plainscape/template.php on line 253.

I'm no coder, so unfortunately I'm not able to do any troubleshooting on my own. I've run update.php and cleared the cache. Also, I did a search of the issue queue and didn't find any similar errors that didn't say they weren't already fixed.

CommentFileSizeAuthor
#8 template.php_.zip3.34 KBkong
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

tiyberius’s picture

I'm getting this too! I restarted the server, cleared the caches, run update.php ... no luck.

Magnity’s picture

Are you both using the theme plainscape or a different one?

Magnity’s picture

Status: Active » Postponed (maintainer needs more info)

(Changed Status - Awaiting more info)

Magnity’s picture

Project: Storm » Plainscape
Component: Storm.module » Code
Status: Postponed (maintainer needs more info) » Active

I have had a look through this issue, and believe that it is caused by the SQL queries done by the theme functions in template.php of Plainscape. These call the rewrite sql function (which Storm hooks into for access management), and conflicts with the labelling of the node table by Storm n.

The easiest resolution would I think be if Plainscape could label the table n also even though there is only one db table used in each query.

butler360’s picture

Ah, thanks for the update.

kong’s picture

Status: Needs review » Active

Hi,

Thanks butler360 and Magnity for the feedback!

I modified the query to use "n" as alias for {node} table. Please wait until the snapshot is regenerated and see if it fix the problem.

kong’s picture

Status: Active » Needs review
kong’s picture

FileSize
3.34 KB

Whoops, I forgot that the -dev snapshot doesn't point to HEAD.

So could you try putting the attached template.php in the plainscape directory and see if it fix the problem?

butler360’s picture

Status: Active » Needs review

That appears to have fixed the problem. Thanks Magnity and kong.

kong’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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