我正在尝试使用控制台应用程序在MSDB上运行我的SSIS包,但我一直收到错误。
Application app = new Application();
Package package = app.LoadFromSqlServer("\\File\\Path\\" + paramName, ".", "MSDBUser", "password", null);
DTSExecResult result = package.Execute();
Console.WriteLine("Package Execution Results: {0}", result.ToString());
我一直收到错误:
"The Execute method on the task returned error code 0x80131621 (Mixed mode assembly is
built against version 'v2.0.50727' of the runtime and cannot be loaded in the 4.0
runtime without additional configuration information.). The Execute method must
succeed, and indicate the result using an \"out\" parameter.\r\n"
我认为这与我调用程序包的方式有关,使我过时,但我不太确定。是否有人能够帮助我并提供一些更好的方法来做这个?任何帮助将非常感激。谢谢!