Hi
I am BRAND NEW to Datastage and am tasked with converting our porcesses from Data Manager to Datastage.
>>> In Data Stage, our task is :
We are trying to use a table accessed through our ODBC connection to an AS400 system as our input Stream.
Our requirement is that the SQL statement use one or more variables in the “WHERE” clause to control the data selection
(i.e., FROM_DATE, or RECORD_TYPE) to allow us to run the same job without modification for multiple RECORD_TYPES (i.e., Forecast vs. Budget).
We have jobs that run just prior to our main job to set the variables in the SQL table to the correct values – based on which system is triggering the ETL job.
Question 1 :
The variables and values exist in a SQL Server table in the TARGET database.
** QUESTION: Is there a method that would allow us to use the values from this control table from the Target SQL Server Database in the ODBC Connector stage SQL code?
>>> WE are able to do this In DataManager, on the JOB stream properties, we define a variable that is resolved by retreiving a value from a table on our TARGET SQL database. I am then able to reference this variable in the FACT BUILD DataStream QUERY SQL statement that uses the ODBC connection as SOURCE.
I know they are very different tools, but my thinking is that there should be some way to accomplish most of the flexibility we had in Data Manager
Question 2:
As an alternative, we have created the parameter and value as a JOB PARAMETER using a Parameter Set/Value Set/Value File(“xx.txt” file). We can successfully access the value of the Job parameter in our ODBC Stage SQL code.
** QUESTION: Using this Job Parameter method, is there a way/process to update the VALUE of the job parameter dynamically/systematically? Using a stage/process/ etc within Data Stage ??
(without manually editing a .txt file? )
Everything I have tried, even though the value appears to be different, the Data Stage SQL keeps reconciling to the original value.
Thanks
I am BRAND NEW to Datastage and am tasked with converting our porcesses from Data Manager to Datastage.
>>> In Data Stage, our task is :
We are trying to use a table accessed through our ODBC connection to an AS400 system as our input Stream.
Our requirement is that the SQL statement use one or more variables in the “WHERE” clause to control the data selection
(i.e., FROM_DATE, or RECORD_TYPE) to allow us to run the same job without modification for multiple RECORD_TYPES (i.e., Forecast vs. Budget).
We have jobs that run just prior to our main job to set the variables in the SQL table to the correct values – based on which system is triggering the ETL job.
Question 1 :
The variables and values exist in a SQL Server table in the TARGET database.
** QUESTION: Is there a method that would allow us to use the values from this control table from the Target SQL Server Database in the ODBC Connector stage SQL code?
>>> WE are able to do this In DataManager, on the JOB stream properties, we define a variable that is resolved by retreiving a value from a table on our TARGET SQL database. I am then able to reference this variable in the FACT BUILD DataStream QUERY SQL statement that uses the ODBC connection as SOURCE.
I know they are very different tools, but my thinking is that there should be some way to accomplish most of the flexibility we had in Data Manager
Question 2:
As an alternative, we have created the parameter and value as a JOB PARAMETER using a Parameter Set/Value Set/Value File(“xx.txt” file). We can successfully access the value of the Job parameter in our ODBC Stage SQL code.
** QUESTION: Using this Job Parameter method, is there a way/process to update the VALUE of the job parameter dynamically/systematically? Using a stage/process/ etc within Data Stage ??
(without manually editing a .txt file? )
Everything I have tried, even though the value appears to be different, the Data Stage SQL keeps reconciling to the original value.
Thanks