SAS Life Science Analytics Framework and the clinical data products from SAS

How can prior versions of an object be retrieved?

Reply
SAS Employee
Posts: 11

How can prior versions of an object be retrieved?

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:

  1. demo.sas7bdat_SDDVer1of2.sas7bdat
  2. demo.sas7bdat_SDDVer2of2.sas7bdat

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.

Contributor
Posts: 22

Re: How can prior versions of an object be retrieved?

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.

Attachment
Ask a Question
Discussion stats
  • 1 reply
  • 362 views
  • 0 likes
  • 2 in conversation