BookmarkSubscribeRSS Feed
luca87
Obsidian | Level 7

Hi, 
I am trying to build a job flow containing a series of scheduled jobs in SASEnvironmentManager viya.
I would need at the beginning of the process to pass a parameter (like a %let type=AA) that goes into the subsequent sas codes.
I found the command Line tab but I don't understand how I need to configure it. 

 

Thanks

Luca

1 REPLY 1
AllanBowe
Barite | Level 11

Hi Luca,

 

Here at 4GL Apps we built an open-source (MIT) framework that you can use to run jobs and flows from command line.  You can pass parameters (as macro variables) and collect return codes.  You can even run it on SAS 9 EBI and Base SAS, as well as Viya!

 

The docs are here:

 

 

I extract the documentation for your perusal:

Syntax

sasjs job <action> <job path> [additional arguments]

Additional arguments may include:

  • --log (alias -l) - path where the log of the finished job will be saved (if used, -w is implied).
  • --output (alias -o) - path where output of the finished job execution will be saved.
  • --source (alieas -s) - Provide the path to an input JSON containing job variables, structured as follows: {"macroVars":{"varname":"value","var2":"val2"}}
  • --target (alias -t) - the target environment in which to deploy the services. If not specified, default target will be used, mentioned in sasjsconfig.json. The target can exist either in the local project configuration or in the global .sasjsrc file.

The following flags are only relevant for serverType VIYA:

  • --ignoreWarnings (alias -i) - If present and return status only is provided, CLI will return status '0', when the job state is warning.
  • --returnStatusOnly (alias -r) - If present and wait flag is provided, CLI will job status only (0 = success, 1 = warning, 2 = error).
  • --wait (alias -w) - if present, CLI will wait for job completion.

 

/Allan
SAS Challenges - SASensei
MacroCore library for app developers
SAS networking events (BeLux, Germany, UK&I)

Data Workflows, Data Contracts, Data Lineage, Drag & drop excel EUCs to SAS 9 & Viya - Data Controller
DevOps and AppDev on SAS 9 / Viya / Base SAS - SASjs

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 606 views
  • 0 likes
  • 2 in conversation