ousoonerjoe
Programmer
Using SQL Server 2005.
I've been trying to copy all data from all tables from our Production database to our Testing database. When I use the Import/Export Wizard, it pukes on the tables with Primary Keys. The options are set as stated below:
Optimize for many tables = Checked
Run in a Transaction = Checked
Edit Mappings
Drop and recreate new destination tables = UNchecked
Delete Rows in existing destination tables = Checked
Enable Identity Insert = True
What am I missing?
Error Statement Returned:
ERROR : errorCode=-1071636471 description=SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "The statement has been terminated.".
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "Violation of PRIMARY KEY constraint 'PK_AbsentCode'. Cannot insert duplicate key in object 'dbo.AbsentCodes'.".
helpFile=dtsmsg.rll helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}
--------------------------------------------------
Bluto: What? Over? Did you say "over"? Nothing is over until we decide it is! Was it over when the Germans bombed Pearl Harbor? No!
Otter: Germans?
Boon: Forget it, he's rolling.
--------------------------------------------------
I've been trying to copy all data from all tables from our Production database to our Testing database. When I use the Import/Export Wizard, it pukes on the tables with Primary Keys. The options are set as stated below:
Optimize for many tables = Checked
Run in a Transaction = Checked
Edit Mappings
Drop and recreate new destination tables = UNchecked
Delete Rows in existing destination tables = Checked
Enable Identity Insert = True
What am I missing?
Error Statement Returned:
ERROR : errorCode=-1071636471 description=SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "The statement has been terminated.".
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "Violation of PRIMARY KEY constraint 'PK_AbsentCode'. Cannot insert duplicate key in object 'dbo.AbsentCodes'.".
helpFile=dtsmsg.rll helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}
--------------------------------------------------
Bluto: What? Over? Did you say "over"? Nothing is over until we decide it is! Was it over when the Germans bombed Pearl Harbor? No!
Otter: Germans?
Boon: Forget it, he's rolling.
--------------------------------------------------