0

I have a table of about 2 million SKU's. Is there a way to detect any sku that occurs more than once by running a select query??

3 Answers 3

7
Select SKU
From table
Group By SKU
Having Count(SKU) > 1
Sign up to request clarification or add additional context in comments.

Comments

2
 SELECT SKUColumn, COUNT(*) FROM YourTable
    GROUP BY SKUColumn HAVING COUNT(*) > 1

Comments

0
select SKU, count(SKU) cnt from table group by SKU having cnt > 1

2 Comments

It will take an awful long time to look through that result set. . .
@Larry: agreed forgot to add having clause

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.