简体   繁体   中英

SSIS Package Error single UPDATE in a execute SQL task

I am trouble shooting an error in a package.

Update MYTABLE for MYCOLUMN (REF to task name):Error: Executing the query "..." failed with the following error: "Invalid column name 'MYCOLUMN'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.

  • I have verified the table and column exists, the length of the field is way excessive than what it needs that is 14 where it is declared as varchar(250).
  • I have verified the script works on the server in SSMS outside of the context of the package.
  • I have verified the connection and database in the package is as I expect. Is there away to verify on the server. I did try to look at the Connection Managers tab on the package configuration itself ie in the Integration Services Catalogs->SSISDB->solutionfolder->..->package.dtsx->Configure context menu but it is empty.

Any ideas on how to troubleshoot?

Just to add more context the package contains 27 other tasks, 9 tasks in a row linked to this task but all set to on completion, all seem to be doing stuff independent of the other. 1 task is a loop doing stuff and the rest are single independent tasks. So I don't know at this stage if it is a cascading connection issue perhaps however; I am just reading what the log says.

I kicked off the package at 9:54am, the timestamp on the error log says 11:45am so nearly 2 hours into running is this log reported.

I would suggest the below things to troubleshoot the issue.

  • I would suggest you to just have this task and disable all other tasks to troubleshoot the issue. So that you can focus on this issue specifically. That will tell you whether connection is working fine without issues.

  • I would suggest you to edit the task and see whether parameters are set properly. Different providers have different way of setting parameters. Again check whether parameters are proper. Execute SQL Task

  • one more thing, may be you are pointing the package to different connection than the one you used for SSMS. So, it is working in SSMS and in the connection being used in the package is not having schema changes yet done.

I finally figure it out before I read the previous offered suggestion so will give some credit if I can! FYI: We have a lot of dev servers. I clicked on the overview hyperlink in the All Execution logs and it said another server. Also I found the connection on the job calling the package not the package itself so I have learnt something today. Anyhow the job said one server but the overview said another so I again I was back to square one scratching my head.

Then I decided to open the connection manager on the job and select the field and make no change rather then cancelling I clicked ok not thinking about it and noticed the field changed to bold face. So I am assuming if you make a manual change on the server in SSMS to anything it shows up in bold which is kind of useful. So I can only assume this is a MS SSMS or SSIS or VS deployment bug. That it does not overwrite, the previous connection although the SSMS interface says otherwise. Perhaps somebody can share some light. Having not checked the server before I made a change and deployed it I have no idea if the previous settings were changed manually by someone or the connection in the package was changed and deployed. Anyhow checking the job history shows it had been failing for awhile so it wasn't me so whoever and whenever a change was done by a previous developer didn't figure it our either or didn't bother or did not know how, or didn't observe it. Anyhow it is pointing to the correct server now!!!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM