Getting true/false from SQL query -
I need to use a query that the customer has purchased 100 or more unique drinks using the SQL query,
I have done this: WHERE patron_email='smith@gmail.com '
from SELECT COUNT (DISTINCT beer_id) orders How do I test whether its The result is 100 or more? Update: Sorry for the unclear question, I have to use standard SQL. This works in MySQL, not sure about other people: < Pre> Just put a boolean position in the bus
SELECT COUNT (DISTINCT beer_id) & gt; 100 ORDERS WHERE patron_email='smith@gmail.com '
SELECT . It will be wrong for the right or evaluate 0 for 1.
Comments
Post a Comment