Create a select query with your fields substituting for my CustomerID and
SaleDate.
Open the query in design view, click on icon the looks like an 'M' on its
side - ∑ - and save the query.
Then create a select query with just CustomerID. Open the query in design
view, click on icon the looks like an 'M' on its side - ∑ - and save the
query. Click on the CustomerID field in the table and drag down to the
FIELD row of the grid. In the TOTALS row of the grid under the second
CustomerID change the GROUP BY to COUNT and save.
Run the second query.
--
Build a little, test a little.
Doug said:
Karl, thanks, but I'm really new to access and don't follow exactly.
I've attempted to build a totals query, but I don't think its done
correctly. Sorry to ask, but could you go into more detail? thanks again.
:
Use a totals query with all fields set to group by. Follow this with another
totals query to count customer entries.
qryCustSales --
SELECT CustomerID, SaleDate
FROM YourTable
GROUP BY CustomerID, SaleDate;
SELECT CustomerID, Count([CustomerID]) AS CountOfCustomerID
FROM qryCustSales
GROUP BY CustomerID;
--
Build a little, test a little.
:
I am trying to count how many times a customer made a purchase.
If they bought 2 items, it appears as 2 records in my table.
How can I eliminate records were the client name and the date are both the
same?
I can find which ones are duplicates, from the duplicate query wizzard, but
I want to count the first record and ignore any duplicate records.
Thanks