I would like to use a control table (sas table) to define (part of) the name of the input file (sas table) in a DIS job.
For instance in the case where we have a large number of jobs reading year specific input files (sas files)
I would like to create a control table (containing for instance the current year 2017) and then be able to use the content of this control table to steer the inputfile name into my job. So in this case my job will start to use the INPUT_A_2017 and INPUT_B_2017 sas files as input for the job and when I change the datafield in the control file to current year 2018, it will run the same job using the INPUT_A_2018 and INPUT_B_2018 as inputfiles. Where of course these input files 2017 and 2018 have the exact same structure.
If someone could point in a direction I could be persuing to achieve this or to existing information that relates to this question that would be nice. I am trying to use as much standard transformations or user defined transformations to keep it flexible and DIS like, rather than coding it out completely.
You want to look for parameterized job. You map the values from your control table to macro variables that you can resolve in your specific job. And then you define your metadata object (SAS file = SAS table?) using the macro variable as part of the physical name.
You want to look for parameterized job. You map the values from your control table to macro variables that you can resolve in your specific job. And then you define your metadata object (SAS file = SAS table?) using the macro variable as part of the physical name.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!
Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.
Find more tutorials on the SAS Users YouTube channel.