He probably didn't get a reply because the only reply is rtfm...

On May 18, 9:17 am, Enchy <[EMAIL PROTECTED]> wrote:
> I actually do need this in my model cause I need to sort it by total
> in the column, so findall is of no use.
> I need this in my main sql query.  I have seen a guy ask this same
> question in 2006 and never got a reply.
>
> On May 18, 2:56 pm, Sliv <[EMAIL PROTECTED]> wrote:
>
> > How to use sql functions in 
> > conditionshttp://cakebaker.42dh.com/2007/05/04/how-to-use-sql-functions-in-cond...
>
> > On May 18, 8:45 am, Enchy <[EMAIL PROTECTED]> wrote:
>
> > >   var $belongsTo = array( 'Orderitem' =>
> > >                          array('className'     => 'Orderitem',
> > >                                'conditions'    => '',
> > >                                'order'         => 'item ASC',
> > >                                'limit'         => '',
> > >                                'foreignKey'    => 'id',
> > >                                'dependent'     => true,
> > >                                'exclusive'     => false,
> > >                                'finderQuery'   => ' '
> > >                          )
>
> > >                                 );
>
> > > Hi I cant find this anywhere.  how do you add a custom query after
> > > SELECT statement.
> > > I just want to add SUM()price as totalprice
>
> > >   'finderQuery'   => 'SELECT item,price,quantity,SUM(price) as
> > > oidPrice FROM Orderitems '
> > > I tried this but it just executes it without the finder.   How do you
> > > include finder into this?- Hide quoted text -
>
> > - Show quoted text -


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to