RE: Limit in SELECT

2001-08-05 Thread Chris Bolt
> Lets say i have 10.000 rows in a table and im searching for only > one record(one row). > > Which one is faster: > SELECT ... LIMIT 1 > or just > SELECT .. The former, since MySQL stops after finding the first row. In the second query, MySQL prepares the entire result set even if you on

Limit in SELECT

2001-08-05 Thread Goran Krajacic
Lets say i have 10.000 rows in a table and im searching for only one record(one row). Which one is faster: SELECT ... LIMIT 1 or just SELECT .. ?