cake-php@googlegroups.com
[Top] [All Lists]

Re: Clueless...Help please

Subject: Re: Clueless...Help please
From: Devario Johnson
Date: Tue, 11 Jan 2011 09:12:16 -0800 PST
that error usually happens when a call to a find query (in this case a
paginate query) is written wrong.  That seems like an app error not
hosting.

On Jan 11, 9:07 am, AD7six <andydawso...@xxxxxxxxx> wrote:
> On Jan 11, 3:37 pm, Ryan Schmidt <google-2...@xxxxxxxxxxxxxx> wrote:
>
> > On Jan 11, 2011, at 07:10, javier0051 wrote:
> > > Code | Context
>
> > > $sql       =       "SELECT COUNT(*) AS `count` FROM `articles` AS 
> > > `Article` LEFT
> > > JOIN `categories` AS `Category` ON (`Article`.`category_id` =
> > > `Category`.`id`) LEFT JOIN `images` AS `Image` ON
> > > (`Image`.`foreign_id` = `Article`.`id` AND `Image`.`thumb` = 1 AND
> > > `Image`.`model` = 'Article') LEFT JOIN `galleries` AS `Gallery` ON
> > > (`Gallery`.`article_id` = `Article`.`id`)  WHERE conditions = ('43')
> > > "
> > > $error     =       "1054: Unknown column 'conditions' in 'where clause'"
>
> > At the risk of stating the obvious, it sounds like there is no column 
> > called "conditions".
>
> a missing field named conditions shouts app-code error to me. Given it
> comes from a paginate call, I guess this is in the code:
>
> ->paginate(array('conditions' => array(43)));
>
> which is simply wrong.
>
> javier I'd suggest doing the blog tutorial before continuing - it'll
> answer these sort of problems for you by example.
>
> AD
> ps. there's a spanish google group cakephp-esp

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@xxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
cake-php+unsubscribe@xxxxxxxxxxxxxxxx For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

<Prev in Thread] Current Thread [Next in Thread>