Sunday, February 19, 2012

get parameter and use in SSIS from SSRS parameter

Hi,
I am not sure this is the correct place to post this question, but here it is. I am trying to pass some parameters to SSIS from a report using the report parameter, then SSIS will create the datareaderdest and return to the report to use.
Anyone have any idea, guidance or leads please share it out. Thanks in advance.
Daren

Not quite sure what you want to to do here. If you want to pass data from SSIS to SSRS then look here in BOL: ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/dtsref9/html/aba8ecb7-0dcf-40d0-a2a8-64da0da94b93.htm

-Jamie

|||Hi Jamie,
what I am trying to do is have a report that has two parameters, lets say param1 and param2. then when user enter the values lets say param1 = 1 and param2 = 5, these two parameters will be passed to SSIS and stored it in the variables I declared there.
do you know how to go about doing something like that? Thanks in advance.
Daren
|||

You can pass values via the command-line to a package when it executes, but those values will not be "stored" in the package so that they are there next time you execute.

-Jamie

|||Hi Jamie,
can you show me an example of how can I send through command-line or give me some guidelines on where I can find examples for them? Thanks in advance.
Daren
|||

Sure, look into the SET option of dtexec:

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/sqlcmpt9/html/89edab2d-fb38-4e86-a61e-38621a214154.htm

-Jamie

|||Thanks Jamie,
I will try that out...
Daren
|||

Hi try using a syntax as follows:

= "/FILE D:\MyProject\\bin\dtsx\myDtsx.dtsx /SET \Package.Variables[var1];" + Chr(34) + Parameters!Var1.Value + Chr(34) + " /SET \Package.Variables[Var2];" + CStr(Parameters!Var2.Value) + " /SET \Package.Variables[Var3];" + CStr(Parameters!Var3.Value) + " /SET \Package.Variables[Var4];" + CStr(Parameters!Var4.Value)

If that works fine in VS environment and if it is giving an error once you deployed to ReportManager? Try specifying a TimeOut value for the SSIS DataSource connection within SSRS.

No comments:

Post a Comment