BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
JM_VFAU
Obsidian | Level 7

I have a  python code on my PC. I would like to call the Python code using SAS EG which is running on application server installed on Linux. By using x commands from SAS EG, it can run commands on the Linux environment. With this setup is there a way to run system commands on windows?

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User
Only if you can run any code locally. If it's set up in this manner, when you click RUN you should actually have a drop down that says run locally or on the server. If it doesn't have that, then you can't run it on your machine.

View solution in original post

2 REPLIES 2
Reeza
Super User
Only if you can run any code locally. If it's set up in this manner, when you click RUN you should actually have a drop down that says run locally or on the server. If it doesn't have that, then you can't run it on your machine.
ScottBass
Rhodochrosite | Level 12

Reeza, as always, is correct, in that if you have Base SAS on your local machine, then EG can launch a local SAS session and, assuming you have ALLOWXCMD, then you can call your python program.  You probably are your own administrator for your local SAS environment, so ALLOWXCMD is likely not a problem.

 

I wanted to also point out this alternative approach:

 

https://blogs.sas.com/content/sasdummy/2013/11/25/11-custom-tasks/, and

https://blogs.sas.com/content/sasdummy/2007/10/05/you-are-under-my-command-prompt/

 

You'll need the ability to install a custom task into EG.


Please post your question as a self-contained data step in the form of "have" (source) and "want" (desired results).
I won't contribute to your post if I can't cut-and-paste your syntactically correct code into SAS.

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 969 views
  • 3 likes
  • 3 in conversation