Hello,
I have an input table that looks similar to the Text Input shown below.
In my workflow I am feeding the output of the 'Text Input' to a 'Dynamic Input' tool. The 'Dynamic Input' tool is configured to connect to an IBM DB2 database.
I want to run a pre-SQL command in order to update a table in a database where only the values in DIV_NBR are updated to the corresponding STAT_CD.
If I use an 'Input' tool, I am able to do this as I can specify which DIV_NBR I want updated. Since the DIV_NBR can change dynamically (in the real application the Text Input will be replaced by an Excel file), I want to configure the Dynamic Input such that it takes the 'DIV NBR' and uses it to update the table for the corresponding DIV_NBR.
Is there a way I can do this? I have attached the sample workflow here. Can you pl advise if this is possible?
Thanks.
Solved! Go to Solution.
Hi @dpakapd ,
I don't believe there is a way to update the pre-sql statement directly in the dynamic input tool but you can dynamically update it by creating a pretty simple macro. Attached is a simple example where you can feed a query into the macro which will overwrite the pre-sql statement in the input tool inside the macro.
Action tool configuration:
Thanks Phottovy!