Would you like to run SAS code on your hackathon Viya 4 instance from terminal, perhaps in VS Code?
Well - you can! Just follow these steps:
1. Install the SASjs CLI - https://cli.sasjs.io/installation. (alternatively, use this gitpod instance: https://gitpod.io/#github.com/sasjs/template_jobs)
2. Run `sasjs auth` and provide your Viya 4 server url (without trailing slash), client id of `hack_client` and client secret of `hack_secret`.
3. Create and save your desired SAS program
4. Run `sasjs run /path/to/your/program.sas`
For more info on sasjs run, see docs: https://cli.sasjs.io/run
i guess this wouldn't work with free sas viya?: https://statisticalhorizons.com/free-sas/ ie could i provide the url created when i launch sas after signing in here?: https://welcome.oda.sas.com/ thanks
Hi @pmbrown ,
The first link you shared is about UE, which has gone the way of the dodo
The second link (ODA) is only SAS Studio, so it does not provide access to the Viya APIs which are necessary for ANY client to connect (not just SASjs)
The only SASjs product you could use with ODA would be the core library: https://core.sasjs.io
If you have Base SAS (desktop) or SAS EBI at work though, you can still use SASjs, including this feature (running code from the terminal). For Base SAS it makes use of SASjs Server (https://server.sasjs.io) and for EBI it uses a Stored Process to inject code.
/Allan
excellent, i do have sas base on the work computer so i will try it there, thanks. My 1st choice was the personal computer because it's linux and everything seems easier, but i have no sas on it
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
If hackin’ is your jam, we’re droppin’ it like it’s PROC with our groovy tune!
Find more tutorials on the SAS Users YouTube channel.