how to query on a subtotal in Access

J

JohnVaTech

Is there a way to query subtotals in Access 2003? Records in my table
contain an amount field and a date field. Amounts can be positive or
negative. A report based on this table is grouped by the date field and then
a sum formula displays subtotals by date. I want to exclude all records for
any date where the subtotal for that date is zero. How can I build a query
to do this? Or, can I do without a query?

Thanks.
 
S

Steve Schapel

John,

The SQL view of such a query would look like this...
SELECT YourDate, Sum(Amount) As SubTotal
FROM YourTable
GROUP BY YourDate
HAVING Sum(Amount)<>0
 
Top