How do you back up SAS Enterprise Miner projects/diagrams without data sets? Currently I manually save diagrams as xml files or create .spk files.
Contributed by David Ogden, SAS Sr. Manager, Analytical Consulting, and Dominique Latour, SAS Distinguished Research Statistician Developer
For flows that are “large”…or have lots of metadata…I’ve experienced an overflow issue when exporting as xml.
There is a more robust way to back-up a flow, while also not backing-up any of the data created by the EM project: saving your flow as a batch program.
Here are the steps:
This large SAS program, if executed, would recreate all the folders, subfolders, and metadata necessary to restore the diagram.
Before executing this program, to restore the project, there are a couple of places that you need to modify this batch program:
%let EM_PROJECT =;
<-- set this to the path where you want the project to get restored to. (by default it goes in WORK)
%let EM_PROJECTNAME =;
<-- set this to the name of the project (by default it’s EmProject)
So, if you wanted the restored project to be in a folder called “flow123” and to be located in the UNIX directory of /gpfs/sasdata/, you would have to modify 2 lines of code found in the flow123_backup.sas batch program as:
%let EM_PROJECT=/gpfs/sasdata;
%let PROJECTNAME=flow123;
Not only is none of the data created by the EM flow restored…but neither is the input dataset. So, after you open this restored project, you’d need to point to the modeling data source, drop it in the project, and re-run the flow.
What do you mean by "open this restored project, you’d need to point to the modeling data source, drop it in the project, and re-run the flow"?
I did all the steps descriped above and now I have a folder called "EmProject" with several subfolders like "Workspaces", "System", "DataSources"....
Where excalty shall we point to the modeling data source?
And is there also a project file that I could use to restore the diagrams in the Enterprise Miner?
@JKarp_11, hi. It sounds like you are able to navigate to see the folder that was created for your EM Project, and it's named EMProject. This is good. For the post, I was mainly just describing the process for how to create this...so that you'd have a project backed-up. If all you wanted to do was back it up, you're done. But if you want to now open that project and use it again...i.e. restore it, then here's what you'd do:
Open Enterprise Miner.
Select to Open a project.
Navigate to where that EMProject folder is. Once you navigate to that, select that folder as the project you want to open.
Now cross your fingers that the project opens. And you are able to see your diagram within that project. If so...
You'll need to create a new datasource. It's important that you create a datasource that has the same variable names and type of content as the data your originally used as your input to the project that you backed-up.
Within the diagram, delete the data input node, and then drag and drop the datasource you just created onto your diagram...to replace the node you just deleted. Connect your datasource into your flow. Now run your flow.
I hope this helps.
Good luck!
-David
@Ogden: Many thanks for your help! I guess my problem is related to the fact that I cannot see/access the created EMProject (which is stored in SAS Server List) from the enterprise miner interface due to access rights problems. I have to get in contact with our admin.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
Data Literacy is for all, even absolute beginners. Jump on board with this free e-learning and boost your career prospects.