1. 1.
    0
    I am running a SSIS package that calls an SP form Mysql DB via a SP. Step1: Get a list of values in a sql server table. Step2: pass each value as a parameter to an SP in mysql. Step3: Once the SP returns data, insert it into a table in sql server after suitable data conversions. When the SP returns data, the package runs fine. However when the SP returns 0 rows then the package fails with the error: [ADO NET Source 1 1 [126]] Error: System. NullReferenceException: Object reference not set to an instance of an object. at Microsoft. SqlServer.Dts. Pipeline.DataReaderSourceAdapter. PreExecute() at Microsoft. SqlServer.Dts. Pipeline.ManagedComponentHost. HostPreExecute(IDTSManagedComponentWrapper100 wrapper).

    My expectation is the package should succeed, not insert any rows into the table if the SP returns 0 rows. I mean why is it throwing an exception in ADO NET Source... Note, the package succeeds if the returns more than 0 rows. I have done quite a bit of search on this issue but without any success. Do help. Workarounds are also welcome. Note: The 'ValidateExternalMetadata' property in ADO net source is set to false. The SP reads parameter from a variable which is extracted from an expressions property in the Data flow task.
    ···
   tümünü göster