Discussion Locked

SQL 2005 DTS

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I've tried everything I can think of. Can't get DTS to work in SQL Server 2005. I get this error every freakin time!

'Violation of PRIMARY KEY constraint 'PK_Alerts'. Cannot insert duplicate key in object 'dbo.Alerts'.

Sometimes it's a foriegn key. I can't figure this out. I try to have DTS drop the tables and recreate but it still fails with same error.

2 replies

by nick.mcdermaid

Unless the error is misleading, that will happen whether you use DTS or SSIS (SQL 2005 version of DTS)

The problem is actually that you have defined that one or more columns are unique, but the data you are importing into it is NOT unique.

You could drop the constraint, but then I'm sure that constrinat is there for a reason.

by mg_roberts

Yea you're right. But if i choose to have it drop the table at the destination and recreate, it shouldn't have any problems. but i still get the same error.

This discussion is closed to new replies.