Home Forums SQL Server 2005 T-SQL (SS2K5) INSERT avoiding duplicate error on multi-column unique index RE: INSERT avoiding duplicate error on multi-column unique index

  • I guess what I am looking to do is INSERT but skip/ignore/don't care about any duplicates.

    Some of these tables that I am working with have multi-column unique indexes and my program ran into the error during a test run. When I looked at the destination table none of the rows from the source table were in it. These Tables are created by another department and they don't want to use the ignore_dup_key option in the unique indexes. So I am trying to determine a way to mass insert from Table1 to Table2 the matching fields without it stopping if there are duplicate rows.