In your original message, you said "You will get a summary of prices by type
in your results." and that is what my query gives you. It returns the sum of
the price columns from any rows that are eliminated by the GROUP BY clause.
What do you want it to return?

> Please strike previous message the query should be:
>  SELECT location, date, type, price,
> FROM products
> ORDER BY location, date, type
> Group By location, date, type
> COMPUTE SUM(price)
>
>> SELECT type, sum(price) FROM products GROUP BY type ORDER BY type


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to