OK sorry.

On Feb 12, 9:58 am, Jeremy Burns | Class Outfit
<jeremybu...@classoutfit.com> wrote:
> Very respectful. Well done. I suspect he does know the answer.
>
> Jeremy Burns
> Class Outfit
>
> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> On 12 Feb 2011, at 04:24, sanjib dhar wrote:
>
>
>
>
>
>
>
> > "HOW TO DO THIS" is not an appropriate title for your thread!
> > by the way
> > ........................this means u don't know the answer right.
> > On Sat, Feb 12, 2011 at 5:10 AM, euromark <dereurom...@googlemail.com> 
> > wrote:
> > "HOW TO DO THIS" is not an appropriate title for your thread!
> > by the way
>
> > On 11 Feb., 18:27, sanjib dhar <sanjibdhar...@gmail.com> wrote:
> > > What will be the function like?Can you please send me.I am new in cakephp.
>
> > > On Fri, Feb 11, 2011 at 6:55 PM, Mattijs <mattijsmeib...@hotmail.com> 
> > > wrote:
> > > > Well,
>
> > > > You can't sum price directly in your query since you are showing each
> > > > record individually as well, so I guess you'll need a combination.
>
> > > > a) in your controller: find('all', array('order' => 'Contractor.name,
> > > > Table.dt'))
> > > > b) in your view: sum up price while iterating. Whenever you get a new
> > > > contractor: display sum and reset
>
> > > > Alternatively, you could create a function in your Contractor model,
> > > > retrieving all contractors with contained items and have that function
> > > > calculate the sum into the contractor results.
>
> > > > On 11 feb, 13:56, "sanjibdhar...@gmail.com" <sanjibdhar...@gmail.com>
> > > > wrote:
> > > > > I have a table
> > > > >         id
> > > > >         buyer_id
> > > > >         item_code
> > > > >         contractor_id
> > > > >         price
> > > > >         dt
> > > > >         item_name
>
> > > > > Now I want display dt(date) wise billing but contactor also will be in
> > > > > sequence like this:
>
> > > > > Contractor    buyer_id          item_code      price
> > > > > item_name
> > > > > A                       12                   2112
> > > > > S                jgj
> > > > > A
> > > > > 14            ..............................................
>
> > > > ---------------------------------------------------------------------------
> > > >  -------------------
> > > > >                                         sum(price)
>
> > > > > B
> > > > ...........................................................................
> > > >  ...........
> > > > > B
> > > >  ...........................................................................
> > > >  ...........
> > > > > B
> > > > ...........................................................................
> > > >  ...........
>
> > > > ---------------------------------------------------------------------------
> > > >  -------------------
> > > > >                                         sum(price)
> > > > > C
> > > > ...........................................................................
> > > >  ...........
> > > > > C
> > > > ...........................................................................
> > > >  ...........
> > > > > C
> > > > ...........................................................................
> > > >  ...........
>
> > > > ---------------------------------------------------------------------------
> > > >  -------------------
> > > > >                                         sum(price)
>
> > > > > how to write the query.
>
> > > > --
> > > > Our newest site for the community: CakePHP Video Tutorials
> > > >http://tv.cakephp.org
> > > > Check out the new CakePHP Questions sitehttp://ask.cakephp.organdhelp
> > > > others with their CakePHP related questions.
>
> > > > To unsubscribe from this group, send email to
> > > > cake-php+unsubscr...@googlegroups.com For more options, visit this group
> > > > athttp://groups.google.com/group/cake-php
>
> > --
> > Our newest site for the community: CakePHP Video 
> > Tutorialshttp://tv.cakephp.org
> > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help 
> > others with their CakePHP related questions.
>
> > To unsubscribe from this group, send email to
> > cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> > athttp://groups.google.com/group/cake-php
>
> > --
> > Our newest site for the community: CakePHP Video 
> > Tutorialshttp://tv.cakephp.org
> > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help 
> > others with their CakePHP related questions.
>
> > To unsubscribe from this group, send email to
> > cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> > athttp://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to