I need some help counting grouped records that have been summed based on some criteria. I have a table where each record is a transaction with an associated account number. An account number may have one or many transactions. I need a summary count of all account numbers where the sum of the Amt_Due
Example
Acct, Amt_Due
123, 13
123, 15
123, 22
124, 40
125, 60
Answer should be
2 Accounts
I know there is a simple answer but I am not seeing it.
Thanks
In your Query By Design. Set your criteria for the Amt due field to:
f...ts.asp?TID=279
Alan
Thanks. Ok, but how do I count the records in which the last running total is less than $50.
First, create an query that includes only two fields, your Acct and Amt Due. Change this query to an Aggregate Query by clicking on the Totals button and changing the Totals Row value from "Group By" to "Sum" under the Amt Due field. And add criteria on this field of "
If you want to just the number of Accts in this list, then create another query using the previous query as its source. Just add the Acct field, change to an Aggegate Query and change the Totals Row value from "Group By" to "Count" under the Acct field.
That did it. Thanks! |