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)

-----Original Message-----
From: Brandon Lewis [mailto:[EMAIL PROTECTED]]
Sent: Monday, May 21, 2001 2:14 PM
To: Chris Bolt; [EMAIL PROTECTED]
Subject: RE: Compute SQL Function Not Supported

Okay I may have been a bit vague on my description.


Is there something similar for compute?


-----Original Message-----
From: Chris Bolt [mailto:[EMAIL PROTECTED]]
Sent: Monday, May 21, 2001 1:07 PM
To: [EMAIL PROTECTED]
Subject: RE: Compute SQL Function Not Supported

SELECT type, sum(price) FROM products GROUP BY type ORDER BY type

> I take it the Computer SQL Function is not support by MySQL and if not is
> there a substitute for it?
>
> If you are unfamiliar with the command it works like this:
>
> SELECT type, price
> FROM products
> ORDER BY type
> COMPUTE SUM(price)
>
> You will get a summary of prices by type in your results.

---------------------------------------------------------------------
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


---------------------------------------------------------------------
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