SSIS package fails when run by SQL Agent - "Invalid character value for cast specification"

2

I have a SSIS package which reads data from .xml and .xlsx files and writes them to staging SQL Server database. The package is deployed to SSIS catalog on Microsoft SQL Server (Enterprise) instance. When the package is executed by SQL Agent job step it fails with the following error message:

SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005

An OLE DB record is available. Source: "Microsoft OLD DB Provider for SQL Server" Hresult: 0x80004005. Description: "Invalid character value for cast specification".

When the same package is run manually from Visual Studio it works just expected. There is no problem with feeding data to staging tables.

Any idea what can caused this issue?

sql-server
ssis
asked on Stack Overflow Jul 2, 2019 by Yorki • edited Jul 2, 2019 by Larnu

1 Answer

2

I finally find an answer and will here share with you how to resolve it.

Even though the parameter Run64BitRuntime =false at Project Properties wchich I had deployed to SSIS catalog it looks like it was actually executed with 64bit mode as at Job Step properties at configuration tab you have option to run it with "32-bit runtime"

Job Step Properties

answered on Stack Overflow Jul 2, 2019 by Yorki

User contributions licensed under CC BY-SA 3.0