list of duplicate records

M

mysterymoose

When I do a query for duplicate records I do get a list of the duplicate
records, however, I only want the duplicate records listed once. Instead I
get the record say a customer listed as many times as the number of orders
entered. I only want list of the costomers that have placed more than one
order. So how do I get this single list of customers with more than one
entry? HELP.
 
O

Ofer

That type of query should return the customer and the amount of orders he
made, and display only the customers with more then one order

SELECT MyTable.CustomerNum, Count(MyTable.OrderNum) AS CountOrderNum
FROM MyTable
GROUP BY MyTable.CustomerNum
HAVING Count(MyTable.OrderNum)>1

Its group by query when the order number used only to count
 
Top