Desktop productivity for business analysts and programmers

Execute SAS project from another SAS project

Accepted Solution Solved
Reply
Contributor
Posts: 73
Accepted Solution

Execute SAS project from another SAS project

Hi masters!

 

I have 3 sas projects in EG with extension .egp and i want automatize the start of the last 2 projects. When the first project finish i want to execute the next project and then the next automatically, how can i do this task?

 

I execute the projects in a Server. In EG I tried to call to another projects with the next statement CALL SYSTEM and from this statement i call to the file vbs that I created in the SAS EG scheduler. The log dont show any error but the project was not started

 

Kind regards


Accepted Solutions
Solution
‎12-27-2017 03:37 PM
Super User
Posts: 9,550

Re: Execute SAS project from another SAS project

Posted in reply to JuanDaniel

Won't do. Your projects are run by EG on the client, while the code derived from the projects is executed by the SAS sessions on the server.

Once your automation needs reach this stage, you should save everything as code to the server, and run the codes on the server from the server's scheduler (or the company-wide scheduler, if such is present).

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
How to convert datasets to data steps
How to post code

View solution in original post


All Replies
Solution
‎12-27-2017 03:37 PM
Super User
Posts: 9,550

Re: Execute SAS project from another SAS project

Posted in reply to JuanDaniel

Won't do. Your projects are run by EG on the client, while the code derived from the projects is executed by the SAS sessions on the server.

Once your automation needs reach this stage, you should save everything as code to the server, and run the codes on the server from the server's scheduler (or the company-wide scheduler, if such is present).

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
How to convert datasets to data steps
How to post code
Contributor
Posts: 73

Re: Execute SAS project from another SAS project

Posted in reply to KurtBremser

Thx @KurtBremser

 

I have an EG in the server and i try execute as I said. There are any way ef execute a project when another have been finished?

 

Kind regards

Super Contributor
Posts: 269

Re: Execute SAS project from another SAS project

Posted in reply to JuanDaniel

Hi Juan,

 

Check this community entry https://communities.sas.com/t5/SAS-Enterprise-Guide/Re-How-to-schedule-SAS-EG-Project/td-p/204954,

it may answer your question.

 

Most likely for situation like your, you'll have to use a Scheduling Tool that, which could a simple scripting language, to a sophisticated Scheduling Tool with GUI and dependency and errors handling, ....etc.

 

Thanks,

Ahmed 

Super User
Posts: 9,550

Re: Execute SAS project from another SAS project

Posted in reply to JuanDaniel

You can use the scheduling options from Enterprise Guide to schedule projects and then run all projects in succession from the scheduler, but you don't run one project from SAS code of another project submitted by EG. That's like scratching your right ear with your left hand through your legs.

 

But I STRONGLY advise to start running SAS code in batch on the server with a proper scheduling tool. Really. I mean it.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
How to convert datasets to data steps
How to post code
☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 4 replies
  • 212 views
  • 3 likes
  • 3 in conversation