DATA Step, Macro, Functions and more

SAS EG project : Advantages and disadvantages

Reply
Super Contributor
Posts: 371

SAS EG project : Advantages and disadvantages

[ Edited ]

Hello expert,

Please, I would like to know more about the advantages and disadvantages of sas EG projet  in general ?

In particular, what's  the advantages and disadvantages of SAS EG Project versus " macro -program"

For the same project  : Pr1

 

> first Method               : using only sas macro-program  %main_project ( this one call other sas macro pograms)

 

> second method        : create a sas EG project contains ( %main_project  and the others macro-programs)

 

Thank you

 

 

 

Super User
Posts: 5,257

Re: SAS EG project : Advantages and disadvantages

It's very little to go on here to give such a design suggestion.
If you can't describe the business issue and constraints, I suggest that you try both me gods and evaluate after a period (which need criterias, which should be based on - you've guessed it: requirements and constraints).
Data never sleeps
Super Contributor
Posts: 371

Re: SAS EG project : Advantages and disadvantages

In the first time, we can forget the business issue.

Super User
Posts: 3,108

Re: SAS EG project : Advantages and disadvantages

Macro programs require hand coding. I can't see any advantage in putting just manual code into EG projects. The whole point of an EG project is use of the automated tasks.

Respected Advisor
Posts: 3,893

Re: SAS EG project : Advantages and disadvantages

I guess what to go for depends on the use case as well as personal preference.

 

If the macros get used in multiple projects then I'd store them in a folder which is part of the SAS Autocall facility and though would keep the code external to the project. But I also like to keep as much of the code used within a project so if these macro programs are only used in this specific project then I'd keep the code in the project.

 

What I normally avoid is to store code externally if only used in one project as this only adds the need for %include statements with path names in it which can add quite a bit of work when migrating EG project to another environment. You would also have to come up with some naming convention or folder structure in order to avoid overriding an external .sas file with a same named object from another EG project.  ...but then may-be there is some versioning requirement and you want to check in your code as .sas files ...so "what's the right design decision" depends on requirements and constraints.

 

 

 

 

 

Super Contributor
Posts: 371

Re: SAS EG project : Advantages and disadvantages

[ Edited ]

@all:thank you all.

@Patrick :

 

as you said "But I also like to keep as much of the code used within a project so if these macro programs are only used in this specific project then I'd keep the code in the project."

In this case , If I have a macro-programs : P1.sas, ..................., Pn.sas in folder  /Test and I add them in SAS EG Project Pr.egp.

In this case , I will store the programs in two places : /test and Pr.egp ? in this case, autocall is better ?

 

 

Respected Advisor
Posts: 3,893

Re: SAS EG project : Advantages and disadvantages

[ Edited ]

@LineMoon In this case , I will store the projects in two places

 

I wouldn't create copies of EG projects as then you'll have to keep all these copies in sync.

 

One of my main considerations for design decisions is maintenance and I certainly would avoid to have multiple active versions of the same code/EG project.

Super Contributor
Posts: 371

Re: SAS EG project : Advantages and disadvantages

sorry, I want to say

I will store the  same programs  in two places ?

Super User
Posts: 17,837

Re: SAS EG project : Advantages and disadvantages

EG allows you to visualize a project/program flow, if done in an organized fashion with a systemic naming and comments method.

 

Code will not allow you see the relationships unless you trace out the programs. The SAS programs can still exist internally as in step 1.

 

 

Super User
Posts: 17,837

Re: SAS EG project : Advantages and disadvantages

At the end of the day it comes down to personal preferences. Unless your company dictates a method. 

 

I would create a small project in each method and you'll get a feel for what works for you. 

 

Look at EG features you don't have in Base, diagrams, multiple process flows, colour coding, prompts, links to Git etc and decide what you need and want. 

Ask a Question
Discussion stats
  • 9 replies
  • 362 views
  • 4 likes
  • 5 in conversation