lists.zerezo.com



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

***BOGO*** Select Query



Hi,

I wanted to know when doing a select query how is it executed : 


If there is 1000 records with price<10, 3000 records with flag='Y' and the table contains 200,000 records.

Select code, description, price, flag from products where flag='Y' and price<10

Select code, description, price, flag from products where price<10 and flag='Y' 

Which one of the query will be faster?  In query 1, will mysql sort the list for flag='Y' then from the list find price<'10'?

Regards,

Velen