Accessor is Invalid - OELDB Command AS400/DB2

Kuldeep Chitrakar 1 Reputation point
2021-11-25T02:23:14.797+00:00

Hi

I am simply executing a UPDATE statement on AS400/DB2 tables using OLEDB command but I am getting

"Accessor is Invalid " error .

Note: I can execute this OLEDB command without connecting it to its previous step.

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,406 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. ZoeHui-MSFT 30,411 Reputation points
    2021-11-25T05:41:24.7+00:00

    Hi @Kuldeep Chitrakar ,

    I'm not familiar with AS400/DB2.

    I did some online research but there is only a little information about this error.

    Here is a same issue that The Microsoft OLE DB Provider for DB2 does not return a valid error object on an SSIS OLE DB source that uses SQL Command. This causes Microsoft SQL Server to return an "Accessor is invalid" error message.

    Check the resolution to see if it could resolve the issue.

    -accessor-is-invalid-error-after-db2-ole-db-provider-does-not-return-a-valid-error-object-dcaa3ab6-1eee-d73f-52a2-5101bdeb0fb1

    Someone mentioned in this thread said, you may have a try.

    When using SQL Server Integration Services with SQL commands containing parameters (WHERE clauses), you must set the optional OLE DB data source initialization property “Derive Parameters” to TRUE. This property instructs the provider to derive parameter information from the data source, upon request of the consumer. You can set this property from the Advanced Options page of the Data Source Wizard, or the All tab of the Data Links dialog. You can specify this property in an OLE DB initialization string (connection string) using the “Derive Parameters=FALSE” argument.

    Set this value to TRUE when using SQL Server Integration Services with parameterized statements that include a WHERE clause (e.g., SELECT, INSERT, UPDATE DELETE).

    You may take a reference to see if it is helpful.

    Regards,

    Zoe


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  2. Kuldeep Chitrakar 1 Reputation point
    2021-11-25T11:01:34.25+00:00

    No, it does not help. I am still getting same error.

    Any other solution. is this a SSIS bug?

    Error:

    [OLE DB Command [12]] Error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80040E00.
    An OLE DB record is available. Source: "Microsoft DB2 OLE DB Provider" Hresult: 0x80040E00 Description: "Accessor is invalid.".

    SSDT : 2019

    0 comments No comments