Created
February 17, 2018 11:38
-
-
Save joshi-kumar/9bdb1b2eb0a45e1382a2111831802b03 to your computer and use it in GitHub Desktop.
Delete duplicate record from table in SQL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
delete FROM dbo.GenrePreference WHERE id NOT IN (SELECT MIN(id) _ | |
FROM dbo.GenrePreference GROUP BY CategoryId) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment