BookmarkSubscribeRSS Feed
r_d
Calcite | Level 5 r_d
Calcite | Level 5

Hello,

 

I have googled far and wide to no avail. I am using the Batch Export Tool (http://documentation.sas.com/?docsetId=bisag&docsetTarget=n008xsxs34mvcwn1qrgcmugpzu6i.htm&docsetVer...).

 

I can successfully use the tool no problem. But I am having an issue in getting 'Folder Objects'.

 

Using the export wizard in DI Studio or Management console, I can right click at the highest folder level and create an export package. If I then select a job, then it will be exported along with all the above folder objects.

 

Using the Batch Export Tool, I cannot find that I can do the same thing. I can select jobs and export them, but it doesn't include the above folder objects. I can select the folder the job is in, and just choose to export jobs (-types Job), but it exports every job in the folder (not what I need, some folders are massive). Lastly, I have tried to export the job, and then separately export the folder, but the option '-types Folder' is not valid.

 

In the end I am trying to achieve a package that can be imported, using the import tool, to a target folder, and within that target folder it keeps the same folder path down to the job (this can be achieved using the manual wizards).

 

Thanks in advance!

2 REPLIES 2
r_d
Calcite | Level 5 r_d
Calcite | Level 5

As usual... I've answered this myself immediately after asking Smiley LOL

 

The solution is.... List the folder path first, e.g. -objects "/Top Folder/My Folder/Daily/" "/Top Folder/My Folder/Daily/Job_Name(Job)" -subprop -types Job

 

This seems to have the effect that, you select the 'Folder Object', you then say exactly which jobs in the folder you want. I'd tried it the wrong way round Smiley Indifferent

BrunoMueller
SAS Super FREQ

Please provide the commands you have tried. The ExportPackage has an option to specify a name pattern you may also explicitly specify the object your interested in.

 

Here is an example using the -name option

ExportPackage.exe -profile <yourProfile> -package "c:\temp\test.spk" -objects "/shared data/stp_samples"  -includeEmptyFolders -name display -nameMatchType STARTSWITH

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 769 views
  • 1 like
  • 2 in conversation