I have write a query to remove duplicate records from a table.
DELETE e FROM
(
SELECT *, ROW_NUMBER() OVER (PARTITION BY emp_id ORDER BY emp_id) AS rn
FROM employee1
) e
WHERE e.rn > 1
But i got this error
ERROR: syntax error at or near "e" LINE 1: DELETE e FROM.
Can someone help me. Thank you!