
Ultimate access to all questions.
You are working on a data cleansing project where you need to handle duplicate records in a large dataset of customer information. The dataset is stored in Azure SQL Database and includes fields such as 'CustomerID', 'FirstName', 'LastName', and 'Email'. Which SQL query would you use to identify and remove duplicates, ensuring that only one unique record remains for each customer?
A
DELETE FROM Customers WHERE CustomerID NOT IN (SELECT MIN(CustomerID) FROM Customers GROUP BY Email);
B
DELETE FROM Customers WHERE CustomerID IN (SELECT MAX(CustomerID) FROM Customers GROUP BY Email);
C
DELETE FROM Customers WHERE CustomerID NOT IN (SELECT MAX(CustomerID) FROM Customers GROUP BY Email);
D
DELETE FROM Customers WHERE CustomerID IN (SELECT MIN(CustomerID) FROM Customers GROUP BY Email);