Guys sorry for my English, I'm from Russia.
I have the following problem
There is a customer table with the fields id and type
I make such a request here
$result = $this->find ( 'count', array ( 'fields' =>
'Client.ClientId', 'group' => 'Client.ClientType'));
I want to know the number of customers of various types;
Making debug($result); and get the number 2, then look at the query in
the debug panel
SELECT COUNT ( `Client`. `ClientId`) AS `count` FROM `Client` AS
`Client` GROUP BY `Client`. `ClientType`
now make
$ result = $ this-> query ( 'SELECT COUNT ( `Client`. `ClientId`) AS
`count` FROM `Client` AS `Client` GROUP BY `Client`. `ClientType`');
debug ($result);
see
Array
(
    [0] => Array
        (
            [0] => Array
                (
                    [count] => 2
                )

        )

    [1] => Array
        (
            [0] => Array
                (
                    [count] => 10
                )

        )

)
This is a cakephp bug or am I wrong create a compelling cost $ this->
find ?
Please help

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 [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