Create variable to pass value to SQL Input

3 posts / 0 new
Last post
Offline
Last seen: 3 years 6 months ago
Joined: 12/04/2013 - 14:17
Create variable to pass value to SQL Input
English

Hi,

Is there anyway to create a variable, change value in the process and pass value into a SQL Input step. In other words, I would like to dynamically generate SQL query.

Offline
Last seen: 5 years 10 months ago
Joined: 09/02/2013 - 10:28

Hi,

I think you're talking about the DatabaseInputStream in Bigateway right ?
If so, there's 2 solutions for your problem.

You can, in the resources view on the right side of the workbench add a variable (with the buttons on the top right of the view).
To use the variable, you need to type the variable name in the query like : select * from customers where id = {$myVarName}
Or you can create a parameter (it's the same as a variable but you will be prompted for the value when you run the gateway).

If that's doesn't answer your question fully please be more specific about what you're trying to achieve so we can find a better solution.

Regards,

Marc.

Offline
Last seen: 3 years 6 months ago
Joined: 12/04/2013 - 14:17

Thanks for the response. What I want to do is load some data from an excel file(example start date and end date) then pass this to an SQL Input through a variable. The next thing I want to find out is how to store data into a variable.