mkrausnick
Programmer
I have two identical SQL Server 2005 tables. I want to merge one into the other in the Management console with the command:
Now previous to this, I check for possible conflicts by executing the command:
This query comes up empty, as does the query when I turn the tables around:
There are no common values in PKField between the two tables. Why do I get a Violation of PRIMARY KEY constraint?
Mike Krausnick
Dublin, California
Code:
insert into MasterTable select * from TransTable
Code:
select PKField from TransTable where PKField in (select PKField from MasterTable)
Code:
select PKField from MasterTable where PKField in (select PKField from TransTable)
Mike Krausnick
Dublin, California