Page 1 of 1

Passing inputs to a SP Stage from another stage

Posted: Sun Jul 19, 2009 12:34 am
by harsh_cs31
Hey,
I'm working on huge sets of data and to load the entire table from the source does not makes sense.
I can write a query to get the required records only but I want to use as little SQL as I can.
I want to write a sp that will have a certain input param which can be passed by say, an ODBC stage.
Based on this input my sp will return the required dataset.
Is there any way to incorporate this?

Regards,
Harsh

Re: Passing inputs to a SP Stage from another stage

Posted: Sun Jul 19, 2009 8:33 pm
by suresh.angadi
Hi Harsh,

you can use the custom SQL along with parametrization and use the arry size as 1000 and transaction size to 10000.

Regards
Suresh
harsh_cs31 wrote:Hey,
I'm working on huge sets of data and to load the entire table from the source does not makes sense.
I can write a query to get the required records only but I want to use as little SQL as I can.
I want to write a sp that will have a certain input param which can be passed by say, an ODBC stage.
Based on this input my sp will return the required dataset.
Is there any way to incorporate this?

Regards,
Harsh

Re: Passing inputs to a SP Stage from another stage

Posted: Sun Jul 19, 2009 8:35 pm
by suresh.angadi
Hi Harsh,

you can use the custom SQL along with parametrization and use the arry size as 1000 and transaction size to 10000.

Regards
Suresh
harsh_cs31 wrote:Hey,
I'm working on huge sets of data and to load the entire table from the source does not makes sense.
I can write a query to get the required records only but I want to use as little SQL as I can.
I want to write a sp that will have a certain input param which can be passed by say, an ODBC stage.
Based on this input my sp will return the required dataset.
Is there any way to incorporate this?

Regards,
Harsh

Posted: Mon Jul 20, 2009 4:19 am
by Grace J.
In the syntax tab of Stage properties of SP stage, set the procedure type to "Transform". Then in the Parameters tab set the input and output parameters as u need...In the Input properties tab, click on "Forward row data" and "Execute Procedure for each row"

Thanks a lot

Posted: Mon Jul 20, 2009 8:54 am
by harsh_cs31
Hey,
Thanks Grace
It sure helped