BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
Baki
Fluorite | Level 6

Okay I have an interesting automatization idea for my ML process that includes SAS EG.

 

Basically, I have SAS EG project that I use to extract client data that will later be used for ML modeling.

I use saspy to establish connection between my SAS Linux server and local windows computer.

Currently, I have EG project, from which I extract .sas file that I store and then use in my automatized process. Now that manual work is sometimes problematic, e. g. I make simple changes in EG and forget to export SAS EG to .sas and replace old versions of .sas files that are used.

I would like to know, is there any way to program (in Python, PowerShell...) script that automatically extracts .sas file from EG project. I have looked at some COM objects that are used for Outlook (and I use them), but I haven't found that kind of solution for EG Project.

So the main idea, I create a script that automatically creates .sas file from SAS EG project, so that every change in SAS EG project will automatically be applied to my ML modelling process that is fully automatized besides this part of .sas code extraction from SAS EG every time I change it.

 

Best regards and thanks for help in advance!

1 ACCEPTED SOLUTION

Accepted Solutions
yabwon
Amethyst | Level 16

1) Don't know.

2) I don't think so.

 

Bart

 

P.S. If I want to have a single file that keeps my code and my order of execution I'm using SAS packages (https://github.com/yabwon/SAS_PACKAGES)

 

 

_______________
Polish SAS Users Group: www.polsug.com and communities.sas.com/polsug

"SAS Packages: the way to share" at SGF2020 Proceedings (the latest version), GitHub Repository, and YouTube Video.
Hands-on-Workshop: "Share your code with SAS Packages"
"My First SAS Package: A How-To" at SGF2021 Proceedings

SAS Ballot Ideas: one: SPF in SAS, two, and three
SAS Documentation



View solution in original post

5 REPLIES 5
yabwon
Amethyst | Level 16

You can use this macro I've wrote some time ago that takes EGP project file and extracts all .sas files from inside.

Here is link to the post:

https://communities.sas.com/t5/SAS-Enterprise-Guide/How-do-I-list-all-programs-included-in-an-egp-fi...

 

Bart

_______________
Polish SAS Users Group: www.polsug.com and communities.sas.com/polsug

"SAS Packages: the way to share" at SGF2020 Proceedings (the latest version), GitHub Repository, and YouTube Video.
Hands-on-Workshop: "Share your code with SAS Packages"
"My First SAS Package: A How-To" at SGF2021 Proceedings

SAS Ballot Ideas: one: SPF in SAS, two, and three
SAS Documentation



Baki
Fluorite | Level 6
Great, thanks!
I will implement it and see how it works.
Baki
Fluorite | Level 6
Just 2 quick questions.
1. If I have links that determine the order of execution of my SAS EG project, is it the creation order of .sas files?
2. Are names of those .sas files that are zipped based on the names of programs that are their source?
yabwon
Amethyst | Level 16

1) Don't know.

2) I don't think so.

 

Bart

 

P.S. If I want to have a single file that keeps my code and my order of execution I'm using SAS packages (https://github.com/yabwon/SAS_PACKAGES)

 

 

_______________
Polish SAS Users Group: www.polsug.com and communities.sas.com/polsug

"SAS Packages: the way to share" at SGF2020 Proceedings (the latest version), GitHub Repository, and YouTube Video.
Hands-on-Workshop: "Share your code with SAS Packages"
"My First SAS Package: A How-To" at SGF2021 Proceedings

SAS Ballot Ideas: one: SPF in SAS, two, and three
SAS Documentation



AlanC
Barite | Level 11

I wrote an extensive C# project that extracted all of the aspects of the EG project files. It then serialized them out to files. This included metadata, etc.

 

EG project files are not structured the same between versions. The code tries to accommodate but I didn't have an example of each one.

 

Look at https://github.com/savian-net/SaviEg

 

https://github.com/savian-net

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!

Register now

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 5 replies
  • 368 views
  • 3 likes
  • 3 in conversation