BookmarkSubscribeRSS Feed
ckx
Quartz | Level 8 ckx
Quartz | Level 8

I've been using SAS since 1985 and like many experienced programmers, I have several issues with Enterprise Guide. Here's my list of things SAS Institute could do to make EG a better environment for programmers:

  • Add batch mode support
    Chris Hemedinger provides a VBScript for running EG in batch mode, for which I'm very grateful. But I'd prefer a more robust solution that bypasses EG altogether, providing maximum execution speed and with options to kill or cancel a job.
  • Add a global macro variable with the full path of a syntax file.
    The file name of the syntax file is available as &_CLIENTTASKLABEL (in single quotes, at least at our site) but there's no way to determine the file path. For clincal studies, some Standard Operating Procedures state that the full name and path of the syntax must be reported in the output. And knowing the file path let's you automatically save the output.
    I know you can get the project's file path but I don't want to go through the trouble of saving the project first.
  • Add an option "Don't prompt to save project".
    I never save projects so I always click "No". But a few times, I clicked "No" a second time when I was prompted to save my syntax!
  • Add an option "Always prompt to save syntax".
    EG will quit if a syntax window is untitled. Often that's just fine but not always.
  • Let the user access logs and output from previous runs
    You can retain the output from each EG run as a separate tab but that would become way too cluttered after 4 or 5 runs. Would it be possible to create a table of contents with older log or output windows?
  • Allow the syntax to be edited by third party editiors
    SAS DM has an "-EEFILECHANGEUPDATES" startup option that allows other programs to edit the syntax and shows the result when the focus returns to SAS DM. The SAS editor is OK but editors such as UtraEdit or the freeware PSPad have much more options.
  • Set keys for switching between windows
    F5 for syntax, F6 for the log, why wasn't this incorporated in EG from the start?
  • Port the Explorer from DM to EG
    It's easier to open datasets in DM and the EG explorer doesn't display catalogs at all.

This is my list of things that could be improved to make EG a better programming environment. Did I miss anything? Or are there points you disagree with?

12 REPLIES 12
Quentin
Super User

Hi,

Well you've got 10 years more SAS experience than I do (and I've only been using EG for a month or so), but I would say...

I don't really see need for batch mode in EG.  That is, if I want batch mode, I can always open a terminal session on the server, and batch submit there.  Or no doubt could even set up UltraEdit to batch submit to the server.  I think EG is an interactive environment, just like DMS is an interactive environment .  (This may be related that I use EG similar to DM SAS, with just one program, or one program that calls other programs via %includes, rather than using the EG process flow to link small code modules. So in the end I have a program I can batch submit without needing help from EG.)

Strongly agree with the --EEFILECHANGEUPDATES point.  I've had problems where I had a program opened in EG, edited in Ultra Edit, and expected to see the edits in EG (cuz it's a link, right???) but nope.  Even within EG, I've started opening the actual stored process .sas file in EG.  If I modify the stored process, the modified code won't be reflected in the .sas file I have open unless I close the project (not just the program) and re-open.  This has caused me some heart-ache!

Agree about keys for controlling windows.  In another thread ( https://communities.sas.com/message/128833#128833 ) Chris H. pointed me toward using ctrl-tab to cycle windows, but I still miss the ability to define function keys for myself.

--Q.

BASUG is hosting free webinars Next up: Jane Eslinger presenting PROC REPORT and the ODS EXCEL destination on Mar 27 at noon ET. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
carterson2
Calcite | Level 5

I too have programmed for many years. C, C++, Java...

cellurl - Google Play

They need to rewrite the GUI using the open source GUI called Eclipse.

Texas-Instruments switched their tools to Eclipse.

IBM backs it, so you know its good.

It saves money.

Having an "inhouse" GUI to maintain is very expensive.

I am sure they want to add features, but I am sure it is extremely labor intensive to do it on their GUI.

ChrisHemedinger
Community Manager

SAS does offer an Eclipse-based development environment for users who build SAS applications.  It's called SAS AppDev Studio.  However, its focus is geared toward developers who want to extend the SAS BI environment with their own web applications, so it may not be fit for a general "SAS programming" environment.  SAS is also an Eclipse Foundation member.

Replicating a SAS program editing/management in Eclipse might make sense, but EG is much more than a programming environment that strives to satisfy "business analyst" personas as well as programmers.  I'll be the first to admit there is still room for improvement on the programming productivity side, but I also believe that EG has made great strides with the 4.3 and 5.1 releases. 

In my current role in SAS Professional Services, at least 50% of my time is spent programming in SAS on various projects.  I work almost exclusively in EG for this task.  (I have obvious biases, so this might not be a completely objective testimonial.)

Chris

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.
ChrisHemedinger
Community Manager

ckx,

You make good points, and we appreciate the feedback.  I'd like to offer some tips that might help to fill the gaps that you identify.

- Full path of the SAS program: if you save the SAS program on disk (not embedded in the project), then you can see the full path and program name in &_SASPROGRAMFILE, a macro variable that EG creates on your behalf.  If you need to know the name/path of your current EG project, you can get that from &_CLIENTPROJECTPATH.  This blog post shows an example of how to use this macro variable to assign a library to the project path.

- Logs from previous runs: you can use the Project Log to collect all logs from all activity within an EG project.  It's the same concept as the complete log window in DMS, though a slightly different implementation.

- File-save prompts: when you save SAS programs external to the project, EG manages them as separate files.  So you'll see prompts for the project (a "document" of your work) and for the program file (.SAS file) separately.  Sorry there isn't a way to put EG into a "program editor only" mode and pretend like there is no project...

- There is no built-in catalog viewer, but you can get it with this custom task for viewing SAS catalogs.

Chris

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.
Chuy
Calcite | Level 5

I would agree that there is a need for some type of batch mode submission via EG for background processing. I can see that it would be difficult to implement, but there is a need. I don't think most users will bring this up as an issue, but I am certain it would be heavily utilized if available.

At my site there is ~60% laptop usage/adoption. Analyst with laptops want the ability to submit process before they leave for the day and still have the ability to disconnect their laptop from the network and take it home as needed. As it is now when they disconnect from the network their EG sessions is terminated.

We have considered a terminal Windows server to augment this short coming of EG but that would require additional licensing cost. Additionally, I have set up several analyst to use a permanent directory instead of the temp directory in there EG sessions so they can pick up where they left off, in some instances this has worked for some users.

Doc_Duke
Rhodochrosite | Level 12

I don't particularly understand the batch issue.  The scheduled tasks can take care of batch submission of the project.  There are some tasks that are only run in EGuide, so I think that it would be impossible to generally decouple tasks from EGuide.  If you are only using EGuide to collect the results of hard-coded SAS, it seems to miss a lot of the power of EGuide.

Quentin, the problem of using of two editors on one file is an OS thing, not an EGuide one.  You can get the same screwy edits by using UltraEdit and EMACS on the same file at the same time.

Doc Muhlbaier

Duke

Quentin
Super User

Hi Doc,

I'm not sure you can blame the OS for EG not letting you know when a file has been modified by something else.  For example on windows, I can open a .sas file in UltraEdit and EG.  If I edit the file in EG and hit save, the second I hit save UE pops up a dialog box that the file has been revised, asking me if I want to reload (before I've even shifted focus to UE!).  If I edit the file in UE, EG does not reflect the update, and will not reflect it until I close the program and re-open.  If I save the file in EG, the edit I made it UE is lost.  Even MS Word handles it better than EG, since Word tries to get a lock on a file.  Which is not an argument for opening a file in multiple apps at the same time.  I've just got so used to UE's notifications, I've come to expect it....

As I'm new to EG, curious as to what tasks you are referring to that can only be run in EG? My understanding is all the EG Tasks are producing SAS code in the background, so all the SAS code generated by EG could be written by a person, and almost all the SAS code generated by EG could be decoupled from EG.  (I say "almost" as I imagine code generated by EG may rely on some automatic macro vars/environment vars that exist only in EG).  I like the idea of having a program that I can run in EG, or locally on my PC in DMS, or batch on my PC, or batch on the server, or .....

Thanks,

--Q.

BASUG is hosting free webinars Next up: Jane Eslinger presenting PROC REPORT and the ODS EXCEL destination on Mar 27 at noon ET. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
ChrisHemedinger
Community Manager

Quentin,

The most common "non-SAS-code" task that people encounter is the Import Data task, which uses a combination of desktop client APIs and SAS code to do the job.

There are a few other items you can capture in your flow that aren't completely pure SAS programs, including: Upload/Download SAS data sets, E-mail as a Step, Export (data or results) as a Step.  (These steps, like Import Data, are possible to implement with SAS programs, but they all require additional software or configurations that EG does not rely on out-of-the-box.)

Chris

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.
Quentin
Super User

Thanks Chris,

As soon as I returned to working after writing that post, I noticed that Import Data Task.  And was curious as to what magic allowed it to read data from an Excel file sitting on my windows PC and import it into a SAS session running on a Linux server.  And then looked at the log and it said, basically "fancy stuff happened here that isn't reflected in the log."  : )

OT: So now I'm back to thinking that if I want a stored process that will read an access database sitting on a windows file server, I need to set up a windows job to periodically copy the file to the linux server (samba on the server allows windows to see the directories) then read in the file using the PCFILES engine I suppose....

--Q.

BASUG is hosting free webinars Next up: Jane Eslinger presenting PROC REPORT and the ODS EXCEL destination on Mar 27 at noon ET. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
nrose
Quartz | Level 8

SAS EG has improved significantly since I started using it when it was 4.1. In particular, the code editor in EG 5.1 is such that it is inconceivable for me now that anyone would want to code in DM or any other editor. Furthermore, with 5.1 and the explore option, it is no longer valid to say that it is easier to explore or open datasets in DM. And as for an option not to save projects, I think that most people do save projects, as projects are an awesome way of organising your files and datasets.

As for the suggestion to rewrite the GUI as open source – WOW, that is a pretty major request. The .NET platform is probably the most powerful programming platform there is. And SAS integrates well with Microsoft Products, so, why would they leave that environment?

The only thing I am waiting for is for EG to have a code editor and debugging capabilities like the Visual Studio development clients which would be awesome. Hopefully this will eventuate with further iterations of SAS EG

Nick

ckx
Quartz | Level 8 ckx
Quartz | Level 8

I agree that EG 4.3 was a big improvement over 4.1 - I have no experience with 5.1. As for DM, my suggestions are mostly on how to retain the good points of DM so it can be put to pasture and no one will miss it. EG certainly does do some things right, like automatically closing datasets and output files. But batch mode and the ability ot use an external editor are things I'd like to keep.

@Doc@Duke, the reason for wanting to use batch mode is efficiency. EG or DM are fine for developing a program but when it's ready I want to run it one last time, check the automatically saved log for errors, warnings but also for relevant notes. For example, a "variable unitialized" can mean that I misspelled a variable and e.g. that its label hasn't beed assigned. I could do this in EG but it's quicker using a text editor. Ctrl-R to run, log is automatically opened, Ctrl-L to list errors, etc.

I also have scripts to run a set of programs sequentially in batch mode. Very useful if the data has changed or just as a finel check for an entire project.

So two more suggestions to make EG a better programming environment than DM:

  • Also scan the log for user-specified notes
    Things like "uninitialized", "missing values were generated" could indicate something's gone wrong. Some warnings on the other hand don't matter (to me), e.g. that a title was too long for SAS/Graph when using the ODS RTF nogtitle nogfootnote options. It would be nice if users could specify which warnings to ignore and which notes to search for and EG would provide a clickable list as well as the Ctrl-E option available now.
  • Improve the editor
    Add the ability to do regular expression replacements as well as just searches. Add an option to submit the text between twol bookmarks. Let the editor select /proc,*run;/ /data.*run;/ /%macro.*%mend/ automatically to run the "task at cursor".
Quentin
Super User

@ckx, if you want to catch notes re uninitialized and missing values generated, one way is with the (undocumented):

  options dsoptions=note2err;

It turns bad notes into errors.  I love it.  I submitted to SAS ballot to add an item to recommend that they make this a supported option.  Not sure if it made it. But I'm hoping the more people start using it, the more likely SAS will make it supported.

I learned about it from Andy Ratcliffe's blog:

  http://www.notecolon.info/2009/10/note-more-about-note2err-aka-be-of-good.html

BASUG is hosting free webinars Next up: Jane Eslinger presenting PROC REPORT and the ODS EXCEL destination on Mar 27 at noon ET. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 12 replies
  • 2782 views
  • 1 like
  • 7 in conversation