On Aug 8, 12:06 pm, Dibyendu Mitra Roy <[email protected]> wrote:
> Hi,
>
> The best possible way to find the count is to use findCount() method in the
> following way:
>
> $condition = array("Provide the condition here..")
> $count = $this->ModelName->findCount($condition); // pass the condition here
>
> All other methods, I believe, are not in 100% conformance to the CAKEPHP
> framework and its documentation thereof.
Which documentation have you been reading.
http://book.cakephp.org/search/findCount
http://api.cakephp.org/class/model#method-ModelfindCount
"deprecated see Model::find('count')"
In any event the OP is going to have/realize a problem (unless they
changed their example code) as soon as they test with a count that
doesn't return the value 1.
AD
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" 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
-~----------~----~----~----~------~----~------~--~---