2012年3月25日星期日

Anyone is aware of this SSIS Error.

Hi Folks,

I developed my ssis package against my local database and i would like to test it against remote server database.For that i have modified all of my connection manager settings still i am getting error on oledb destination and Execute T-Sql task.The below is the error.


[OLE DB Destination [11665]] Error: 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__tblPr__532FC765'. Cannot insert duplicate key in object 'dbo.tblPr'.".

Can anyone suggest me what would be the problem and how to resolve this.

Thanks in Advance.

Violation of PRIMARY KEY constraint 'PK__tblPr__532FC765'. Cannot insert duplicate key in object 'dbo.tblPr'.

This means you are trying to insert a key which is already in the table tblPr. Primary Keys have to be unique.. to identify a specific row.

for example (ID is your Primary Key):

ID | SomeColumns
1 | test
2 | testasdf

and now you are trying to insert

1 | anothertest

the column ID (which is your primary key) has already a row with 1 so you can't insert a second row with ID 1

this is just an explanation of your problem .. but i can't help you without any further information... maybe you can fix it on your own when you understand it Smile

- paul
|||

Hi Paul,

I made the changes It works now.Thanks.

I am getting one more error when i am executing Execute T-sql Task.I am using identity column in my tsql statement.

Below is the error.

"User 'guest' does not have permission to run DBCC CHECKIDENT for object '#TempPr__000000000ACC'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.

Please let me know what is wrong if you know..

Thanks so much.

|||

A search on the Internet will yield very helpful results. This is a permissions issue, just as the error says.

Read up on DBCC CHECKIDENT.

http://msdn2.microsoft.com/en-us/library/ms176057.aspx

没有评论:

发表评论