Advertisement
MatthijsFontys

Delete all double entries sql

Apr 10th, 2019
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.19 KB | None | 0 0
  1. SELECT DISTINCT * INTO #tmp FROM dbo.User_Release
  2. DELETE FROM dbo.User_Release
  3. INSERT INTO dbo.User_Release                
  4. SELECT * FROM #tmp DROP TABLE #tmp
  5.    
  6. SELECT * FROM dbo.User_Release
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement