Here is another very common question I often received, which candidates face in the interview.
Question: How to delete duplicate rows in SQL Server (considering there is an identity column in table)?
Answer: Well, there is no better answer than following a script. If you ask me this question in the interview, I will even have to look up online and find following script:
WHERE ID NOT IN
GROUP BY DuplicateColumn1, DuplicateColumn2, DuplicateColumn3)
Here is the quick video I have recorded where I demonstrate the same functionality in simple words.
Reference: Pinal Dave (https://blog.sqlauthority.com)