What response/results are you getting?  Tt would help us to determine the
problem

-----Original Message-----
From: James Cox [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 28, 2001 7:13 AM
To: [EMAIL PROTECTED]
Subject: GROUP BY behaviour.. help needed..


Hello,

This is the following SQL statement used in a results page for a search:

SELECT icaref, id, date, payee, descript, disb, payment, receipt-payment,
receipt, SUM(disb),
SUM(receipt-payment)
FROM data
WHERE receipt-payment > 0 AND date BETWEEN 'varStart' AND 'varEnd'
ORDER BY date
GROUP BY disb, receipt-payment


why does it not work?

and can someone help me understand groups better ?

Thanks,

James Cox


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