It looks like the first query is working as it should. I  am positive
there is a location field.

Here is a snapshot of the table



When I run the first query it works fine and returns 2615 records.

I think it has something to do with the pagination perhaps?

On Oct 25, 1:50 pm, Jeremy Burns | Class Outfit
<jeremybu...@classoutfit.com> wrote:
> Are you certain you have a row in your database that matches that criteria? 
> The SQL looks right, but the count is zero. What happens when you run the SQL 
> directly against the database?
>
> Jeremy Burns
> Class Outfit
>
> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> On 25 Oct 2010, at 13:46, Briko03 wrote:
>
> > I have a field named location.
>
> > This is what is coming throu from cake
>
> > SHOW FULL COLUMNS FROM `results`           14      14      3
> > 2  SELECT CHARACTER_SET_NAME FROM INFORMATION_SCHEMA.COLLATIONS WHERE
> > COLLATION_NAME= 'utf8_general_ci';         1       1       1
> > 3  SELECT `Result`.`id`, `Result`.`racenum`, `Result`.`bib`,
> > `Result`.`fname`, `Result`.`lname`, `Result`.`sex`, `Result`.`class`,
> > `Result`.`team`, `Result`.`firstrun`, `Result`.`secondrun`,
> > `Result`.`best`, `Result`.`points`, `Result`.`season`,
> > `Result`.`location` FROM `results` AS `Result` WHERE
> > `Result`.`location` = 'Sundown'            2615    2615    7
> > 4  SELECT COUNT(*) AS `count` FROM `results` AS `Result` WHERE 1 = 1
> > 1  1       0
> > 5  SELECT `Result`.`id`, `Result`.`racenum`, `Result`.`bib`,
> > `Result`.`fname`, `Result`.`lname`, `Result`.`sex`, `Result`.`class`,
> > `Result`.`team`, `Result`.`firstrun`, `Result`.`secondrun`,
> > `Result`.`best`, `Result`.`points`, `Result`.`season`,
> > `Result`.`location` FROM `results` AS `Result` WHERE 1 = 1 LIMIT 100
> > 100        100     1
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd 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 cake-php@googlegroups.com
> > 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?hl=en

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 cake-php@googlegroups.com
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?hl=en

Reply via email to