Shankar M

Shankar M

  • NA
  • 55
  • 2.8k

Remove duplicates

Feb 28 2018 1:12 AM
The below commnand ran successfully when i click the respective button but no changes on the database
 
SqlCommand command = new SqlCommand("select distinct * into #tmp From bounce delete from bounce insert into bounce select * from #tmp drop table #tmp)", connection);
connection.Close();
MessageBox.Show("Cleared Duplicates");
 
Note: Table bounce having only one column called email to remove the duplicates I created this button function

Answers (12)