We have a scenario in that, We need to compare staging table with Destination table.Finally, want to delete the record at destination table
We tried
DELETE FROM DestTable
FROM DestTable d
LEFT JOIN StagingTable s ON d.ID = s.ID
WHERE s.id IS NULL
Please advice on it. How do I create delete statement in this scenario?
Any help on it would be much appreciated?