Jump to content

suddenly Unknown column 'cl.id_shop' in 'where clause'


Recommended Posts

What just happened to my site?

I have not made any changes for a long time, suddenly i get this error:

 

[PrestaShopDatabaseException]

Unknown column 'cl.id_shop' in 'where clause'
 

SELECT cl.`meta_title`, cl.`link_rewrite`
            FROM `ps_cms_lang` cl
            INNER JOIN `ps_cms` c
            ON (cl.`id_cms` = c.`id_cms`)
            WHERE cl.`id_cms` = 4
            AND (c.`active` = 1 OR c.`id_cms` = 1)
            AND cl.`id_shop` = 1
            AND cl.`id_lang` = 1 LIMIT 1

at line 635 in file classes/db/Db.php

 

629.             WebserviceRequest::getInstance()->setError(500, '
 '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);
630.         }
631.         else if (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS'))
632.         {
633.             if ($sql)
634.                 throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');
635.             throw new PrestaShopDatabaseException($this->getMsgError());
636.         }
637.     }
638.
639.     /**
Link to comment
Share on other sites

  • 2 months later...

Hi,

sorry for my english but i've the same problem, i've you found a solution to shis?

 

thks a lot !

 

Hi Hoover91

 

I did solve it but from help at Reddit.

Prestashop forums is not very useful.

 

Here is the link to the reddit support I got.

https://www.reddit.com/r/prestashop/comments/3f5uhk/prestashopdatabaseexception_unknown_column_clid/ 

If you have any issues following, please let me know. Also feel free to reply on the Reddit post. As the other person who found the solution can also help.

 

Thanks

 

Karan

Edited by karant (see edit history)
Link to comment
Share on other sites

  • 11 months later...

Hi there,

 

I'm sorry to disturb you with upping this old topic but i've got a real problem when i post a product comment.

 

As you can see above when i post a message i've got this error message in my console :

 

SELECT p.*, pl.params, pl.id_lang
                FROM ps_appagebuilder p
                    LEFT JOIN ps_appagebuilder_shop ps ON (ps.id_appagebuilder = p.id_appagebuilder AND id_shop=1)
                    LEFT JOIN ps_appagebuilder_lang pl ON (pl.id_appagebuilder = p.id_appagebuilder)
                WHERE
                    pl.id_lang=2
                    AND ps.id_shop=1
                    AND p.id_appagebuilder_positions IN (45,message,47,48)
                ORDER BY p.id_appagebuilder

 

 

He tries to post in "message column", but "message" it's a word who i wrote in my comments. Normally he needs to post in "46 column" et insert this text : "message".

 

I don't know where i can find this file to change this... Somebody can help me ? About a month i try to solve this issue :(

(obviously no support to help me :().

 

Thank a lot 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...