Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pass Variables to Project Parameters in SSIS

I am new to this network. Hoping I'll find an answer to this problem.

I have a SSIS Project with multiple Packages which are using the Project Parameters. I am trying to update the Project Parameters e.g. @PeriodStart: 2014-05-31. I can't find a way to dynamically write to the Project Parameter.

I am using Visual Studio 2010 in 4.0 Framework. Please can anyone shed light on this ?!

Kind Regards Bal

like image 436
Bal Avatar asked Jul 31 '14 14:07

Bal


People also ask

How do I pass variables in SSIS package?

Open the package in SQL Server Data Tools, and then click the Parameters tab in the SSIS Designer. Click the Add Parameter button on the toolbar. Enter values for the Name, Data Type, Value, Sensitive, and Required properties in the list itself or in the Properties window.

How do you pass a variable in an execute task in SSIS?

Execute SQL Task in SSIS allows user to execute parameterized SQL statement and create mapping between these parameters and the SSIS variables. To add a parameter into a SQL statement you must use a parameter marker which differs based on the connection type. Select * from table where ID > ?

What is the difference between variables and parameters in SSIS?

Variables values can change at run time but parameters value can't change . Variables can be used only with in the package we can't use it for other package with in the solution but we can use Parameters for multiple package (package exist with in the Solution Explorer ).


1 Answers

Project parameters are read only. What you are after is to assign variables depending on the project parameters and then read the variables. An overview of variables and parameters is here:

http://social.technet.microsoft.com/wiki/contents/articles/22194.use-ssis-variables-and-parameters-in-a-script-task.aspx

For example, you could add a script task to the control flow and then read in the project parameters, assign a readwrite variable to the script task and then use this variable.

like image 117
Robert Anderson Avatar answered Oct 07 '22 16:10

Robert Anderson