I saw a couple of old threads on the subject, but none described a way to do mass updates to SAS program properties in version 8 of Enterprise Guide. Now that we're on version 8, I'm hoping there's actually a way to do this:
How can I do a "bulk" change on the program properties of my SAS programs in enterprise guide? On our old server, the path was U:\Tools\SAS\Macros but on the new server, the path is U:\Tools\SAS\Pgm\Macros. Yes, I can change the properties one at a time, but ugh, that's tedious with 50+ programs in the folder -- and this isn't the only folder that's changing. I could also delete all the programs from the project, select-all in Windows File Explorer, and drag and drop them into the project, but I'd lose sort order (the programs are arranged in alphabetical order in the project).
I'd like to change the properties en masse. Is there a way to do this in version 8?
Thanks,
Jim
Hi @jimbarbour - I'm here. Haven't yet checked out for the holidays -- but soon!
As far as I know, there isn't a way to bulk-process the SAS program file references you have in your project. That is, no supported method for this.
Tools->Project Maintenance can change the server and metadata references for you, including data locations and folder locations. However, I don't think it covers the SAS programs that are added basically as shortcuts within your project.
It's no secret that the project file is a zip archive and that the main "directory" of project contents is an XML file. However, SAS does not provide a tool or documentation for manipulating that. Even so, customers have done it. If you decide to experiment along this path, do I need to remind you to make backup copies of your EGP files? I hope not. SAS support can't really help you to put the puzzle together again if it goes to pieces.
Hi, Jim
I feel your pain! I was in the same situation a couple of years ago, and searched around for the same thing. I didn't find anything, so I just bit the bullet and did it manually (I only had about 25 programs).
If I was in your spot, my first stop would be EG automation (scripting). I just took a quick look around it, and I can't find anything right off the bat, but I guarantee I know two people who can answer this! @CaseySmith and @ChrisHemedinger
Tom
Thank you, Tom.
I half wonder if there might be a way to do this as a Custom Task. I'd be very curious if @ChrisHemedinger has ever taken a shot at writing a custom task for such a purpose. This can't be the first time the issue has come up (Well, and as a matter of fact, I looked at a couple of old threads on this very subject).
Jim
Unless I'm badly mistaken, the mechanism I'm describing is the one that is used in writing a custom task, so that is indeed the question of the hour. Hoping to hear more about this soon! Unfortunately, the documentation is just a little too dense, and I'm not familiar enough with it, to be able to say.
If we don't hear anything soon, I'll dig down another layer, and see if I can find anything. You'll owe me a drink at SGF!
Tom
I almost wonder if there's a way to serialize a project to XML. If there were, then one could write a program fairly easily to manipulate the XML.
Tom, if my company, which is notoriously tight on travel expenses, sends me to SGF this coming year in Washington D.C., I'll buy you a lot more than a drink: I'll buy your entire dinner. I am however hopeful that I might be able to attend SGF in 2021 when it is in San Diego which is a whole lot more accessible (I work about an hour and a half by car north of San Diego).
Chris must be taking some time off; he's usually really on top of these Enterprise Guide posts. I can't begrudge him some time off this time of year. I'd be taking some time off too if I had any accumulated vacation.
Jim
Hi @jimbarbour - I'm here. Haven't yet checked out for the holidays -- but soon!
As far as I know, there isn't a way to bulk-process the SAS program file references you have in your project. That is, no supported method for this.
Tools->Project Maintenance can change the server and metadata references for you, including data locations and folder locations. However, I don't think it covers the SAS programs that are added basically as shortcuts within your project.
It's no secret that the project file is a zip archive and that the main "directory" of project contents is an XML file. However, SAS does not provide a tool or documentation for manipulating that. Even so, customers have done it. If you decide to experiment along this path, do I need to remind you to make backup copies of your EGP files? I hope not. SAS support can't really help you to put the puzzle together again if it goes to pieces.
Oh, I LIKE that! A new, totally useless, thing for me to play with.
I think a better analogy would be putting Humpty Dumpty together again once there's a puddle of eqq yolk on the ground!
Merry Christmas everyone!
Tom
YOU are awesome. Awesome, awesome, awesome. Did I mention awesome? (It worked!)
Man! That was SO easy. That's exactly what I wanted. I was thinking that there was a way to do it through XML. I had some vague memory from... Well, you helped me (a lot) in 2015 with automating a virtualized Enterprise Guide project, so maybe it's from then.
Sorry, @TomKari, but I think it's @ChrisHemedinger that I owe dinner to. However, I'm still good for a drink if I can figure out a way to attend SGF 2021...
Thank you to you both!
Jim
Well, @jimbarbour, I'd like to argue but since @ChrisHemedinger provided a solution and all I contributed was witty comments, I don't have much of a leg to stand on. I too am in the line of people who owe Chris dinner; I don't know how he manages to stay so slim!
If we both make it to an SGF, let's solve the problem by buying each other drinks! 😊
Best,
Tom
let's solve the problem by buying each other drinks!
Well, Tom, I must say: I like the way you think. 😉
Merry Christmas/Happy Holidays,
Jim
Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.
Register today!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.
Select SAS Training centers are offering in-person courses. View upcoming courses for: