Hm,
findCount('Install_Count',0) works fine
findCount('Status',0) does not work (returns 0)
Both Fields are in the same table and both are the same data-type
(VARCHAR 255)
Is this a bug in CakePHP? Is 'Status' a keyword? How can I use this as
normal Table Field for findCount?
I have searched the whole CakePHP Code for "Status", but I did not
find anything suspicious.
I'd be glad for any hint!
On 8 Mrz., 18:00, "phirschybar" <[EMAIL PROTECTED]> wrote:
> try:
>
> $this->set('test', $this->Rat->findCount('Install_Count = "7"',0));
>
> quotes around the 7. does it work? might be because it is a varchar
>
> On Mar 8, 10:48 am, "szeta" <[EMAIL PROTECTED]> wrote:
>
> > Hello,
>
> > if I'm using
>
> > $this->set('test', $this->Rat->findCount('Install_Count = 7',0));
>
> > I get a result, but if I do it on
>
> > $this->set('test', $this->Rat->findCount('Status = 7',0));
>
> > (the only difference is the given Condition Field)
>
> > I always get "0" in return, even if i know that there are several "7".
> > A direct Select Statement with "WHERE Status = 7" works fine.
>
> > Both fields ("Status" and "Install_Count") are a VARCHAR(255)
>
> > Any suggestion how I may count my "Status"?
>
> > Regards
> > Ralph
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---