Re: Pagination "Group By" Problem

2008-03-28 Thread phpjunk

i think you can find your answer at the following site:

http://www.littlehart.net/atthekeyboard/2008/03/04/custom-cakephp-12-pagination-queries/

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
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
-~--~~~~--~~--~--~---



Pagination "Group By" Problem

2008-01-29 Thread [EMAIL PROTECTED]

Hello,

I'm using CakePHP 1.2 and I'm in this scenario in which I need to
retrieve all the authors in my "authors" table and also I need to
count the number of articles (from "articles" table) under each
author.

I already have the articleCount in where I inserted it under 'fields'
array of paginate but
the problem is, I'm having difficulty on where to put the GROUP BY
articleCount.

I know this can be done using findAll()..but I don't have any idea on
how to do this using paginate. I've read a lot of threads about
pagination problem but somehow I can't find a good answer in relation
to this problem. I hope someone can help me here.

A good solution is very much appreciated. Thank you very much for your
time.


-- Wendell

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
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
-~--~~~~--~~--~--~---