Basically i am trying to build an application that uses SSIS to run a series of sql stuff.
Here is my code thus far:
public JsonResult Fire
Try that:
Microsoft.SqlServer.Dts.RunTime.Variables myVars = package.Variables; myVars["MyVariable1"].Value = "value1"; myVars["MyVariable2"].Value = "value2"; Microsoft.SqlServer.Dts.Runtime.DTSExecResult results = package.Execute(null, myVars, null, null, null);
You need to use the Package.Variables property.
Package package = null;
package = app.LoadPackage(@"C:\ft\Package.dtsx", null);
package.Variables["User::varParam"].Value = "param value";