06-22-2012 04:41 PM
The archive function within SDD creates separate files for each version of an object in the directory being archived.
If you archive a directory, a jar file is created containing all of the files in that directory.
That jar file is written to the archives folder in the SDD instance.
If there are any versioned files in the directory, they will appear in the archive with an extension of "SDDVerxofx".
Here's an example:
If saving the .jar file to a Windows machine, the extension will need to be renamed from .jar to .zip.
Prior versions of a files can also be retrieved using the Remote API.
08-13-2012 09:03 AM
Attached is the Java Program which when executed after proper setup can extract the previous versions information for the file or dataset into text file.
Below steps provide guidance in setting up the environment to excute attached Java Program.
1. Download the latest SDD API from SAS Drug Development 3.5 Hot Fixes
2. We used Eclipse editor to develop and execute this code. You can download latest version of Eclipse Classic from Eclipse website.
3. Download JDK from Oracle website.
4. Import the Java program into new Project and add reference to the SDD Java API jar files and JDK
5. Update the below code lines in Java program
String aURLStr= "https://<SDDINSTANCE>.sas.com/sddremote"; // REPLACE <SDDINSTANCE> WITH YOUR SDD INSTANCE NAME;
String aUser= ""; // ENTER YOUR USERNAME;
String aPwd = ""; // ENTER YOUR PASSWORD;
String SDDPath="/SDD/Training/trainer/data/demo.sas7bdat"; // REPLACE IT WITH VERSIONED FILE FULLY QUALIFIED PATH;
Attached Java program can also be convereted into jar file and excuted.