BookmarkSubscribeRSS Feed
Huub
Fluorite | Level 6

Hi,

I have a SAS EG file with a process flow with multiple programs and copy programs (see screenshot). At the start of this process flow i have to define a macro variable which is then used throughout the rest of the flow. I am trying to create a loop so that I can insert a list of values for this macro variable where SAS will run an iteration of this flow with one of the values of this list as the macro variable. Is this possible? I have tried using an %include function to call this file from another file and execute it but it gives different errors each time i run in ( Open recursion and ERROR: Maximum level of nesting of macro functions exceeded.)

 

Screenshot of the processflow that i would like to loop

Huub_0-1645630261422.png

screenshot of the program which runs the %include line + one of the errors.

Huub_1-1645630357746.png

 

4 REPLIES 4
SASKiwi
PROC Star

Your screenshot suggests you are trying to %include an EGP. %include only works for SAS program files which normally have an extension of SAS.

Huub
Fluorite | Level 6

Hi,
Thanks for your response.

Do you know how I can convert the .egp file to as .sas file? Or do I have to save all the different programs? If so how do I save a copy program as a .sas file?

 

Kind regards,

Huub

Huub
Fluorite | Level 6

Hi,

I run SAS EG 8.3 but I don't see this option. Is there another way to do this?

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

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.

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
  • 4 replies
  • 706 views
  • 1 like
  • 3 in conversation