BookmarkSubscribeRSS Feed

I just came from an EXCELLENT talk on Enterprise Guide for Programmers at Boston Area SAS Users Group, by Chris Bost.


The talk is available at:


Not surprsingly in a room full of programmers, during the discussion the question came up, "can I do a batch submit?"


And I think currently, the correct answer is "no, you can't, because EG is an interactive environment, in the same (similar) way that DM SAS is an interactive environment."


Chris B. helpfully pointed out that you can schedule an EG project, which accomplishes something like a batch session.


But here's the thing.  When I programming in SAS, I was taught that I should ALWAYS submit my final code as a batch job.  There are two main benefits.  1. You ensure that your code works on it's own, and isn't working (or failing) because you have a lot of temporary datasets / formats / macro variables / whatever assembled junk sitting in your work library.  2.  You get a log file.


During discussion it was suggested by someone that might be nice if EG just had a "batch submit button."  I think it's a grand idea.  If I press "Batch Submit", I want EG to spawn a new SAS session on the server, and execute my program in that new session, then return the results as usual. Getting a log file would also be nice, but that is a separable issue (and PROC PRINTTO is available as a workaround).


Now when using EG, it seems like there are approximations of ways to ensure that you have a clean session to run your code in:

1.  Schedule the flow.

2.  Write a macro that will try to clean up your session (delete temp datasets/filerefs/librefs/macro vars/etc etc)

3.  Disconnect from the server and then reconnect.  (I feel like EG is unhappy with me when I do this, maybe it's because my code is linked instead of embedded in the project, I think EG loses track of the links when I disconnect)

4.  Close EG and restart it.


To me, those are all work arounds for not having a batch submit  button.  Sounded like a grand idea to me, so wanted to throw it out to the group.




(edited 12/10/13 to add link to slides from presentation, and make clear that "Chris" is Chris Bost, not Chris H.)

Obsidian | Level 7

As far as I can see, OP's request was made in 2013. Now we're in 2023 and what I can see, at least for what I can understand of the system, in my company we're having a "batch scheduler submission" for SAS EG processes, but still all made by Windows Task Scheduler (which will then start the VBS scripts on the server).

My hope, for the future, is to see a "SAS Batch Scheduler", as a SAS (base) component, which implements an abstraction layer for the feature, so that it will run above the servers/hosts own architecture (Windows server, Linux, *nix, ZOS, etc.), implementing time-based SAS EG procedures' scheduling (e.g. "every" minute/hour/day/week/time/N-times) not directly tied to the server/host own scheduling process (Win Task Scheduler, Cron, etc.).

That 'cause, many of the times, who works with SAS is not the same person/team which manages the servers and/or SAS system components, thus having limited interaction with the server processes itself.

Super User

@lc_isp yes, this is an old ballot item, and unlikely to be implemented as my understanding is SAS Studio is the IDE of the future, and EG is probably "functionally stable" (don't expect future development work).  This ballot item was just about being able to batch submit.  To be fair, EG is an interactive environment (like Display Manager).  I don't think you can batch submit from display manager either.  But I would still like the ability to batch submit from EG in a SAS 9 metadata / BI server environment, because EG is good at handling all the metadata  / server connection stuff and I can focus on SAS code.


For scheduling on our old server I could use DI studio to create a job and then a flow and schedule the flow using SAS Management Console / LSF.  It worked well, if more steps than cron.  On current server I have to put in a ticket to schedule a job.


It looks like Studio / Viya does have features for creating and scheduling jobs, e.g. .  So that might be a path forward to explore.

Obsidian | Level 7

Hi @Quentin,


Your last link about Studio/Viya seems the way we're having batch submission/projects scheduling right now but, as I told, they're still tied a lot to the underneath OS: that's why I supposed there could be a proper SAS component, not embedded into SAS EG but which can read EG projects and abstracted the OS features (task scheduler, cron, etc.) which physically implements them.

TYVM for the current development highlights.