Module BatchRepositoryService

Macros to perform batch operations in the repository.

Since: 2.1

Macro Summary
external

LSAF
%lsaf_downloadaszip(lsaf_path=, local_path=, lsaf_overwrite=0);
Downloads a SAS Life Science Analytics Framework file or folder along with its content ...
external

LSAF
%lsaf_uploadandexpand(local_path=, lsaf_path=, lsaf_enableversioning=, lsaf_versiontype=, lsaf_customversion=, lsaf_comment=);
Uploads and expands the contents of a ZIP file into the specified folder location in the SAS ...

Macro Detail

%lsaf_downloadaszip(lsaf_path=, local_path=, lsaf_overwrite=0);

[ Exposure: external ]
Downloads a SAS Life Science Analytics Framework file or folder along with its content
to a local computer as a ZIP file.

If the local directory does not exist, it is created. If the local file does not exist,
it is created. If the item to download is a folder, the contents of the folder are
downloaded and the hierarchy is maintained. If the item to download is a context, the
containers (child contexts and folders) and files are downloaded.

NOTE: This macro is supported only from a PC SAS session. Using this macro within an active
SAS Life Science Analytics Framework application session results in a failure.

Syntax:
%LSAF_DOWNLOADASZIP(LSAF_PATH=lsaf-path, LOCAL_PATH=local-zipfile-path
<,LSAF_OVERWRITE=lsaf-overwrite> );

          
History:
   2013-08-30
updates for standardization and coding conventions
   2016-08-26
rebrand as LSAF
   2018-01-09
updates for LSAF 5.1
   2020-11-24
updated for service refactor.
Expected Macro Variables:
_lsafMsg_ - The return message.
_lsafRC_ - The return code.
Parameters:
lsaf_path - - Required - The path of the item to download.
local_path - - Required - The full path and name of the file to create (or overwrite,
        if applicable) on the local computer. File extensions are entered on the file
        as entered by the user. If no extension is entered, it results in a ZIP file
        with no extension.
lsaf_overwrite - - Optional - Indicates whether to overwrite the existing ZIP file on
        the local computer. Valid values:
        - 0 (Default): Maintain
        - 1: Overwrite
File: lsaf_downloadaszip.sas
First available in version: 1.4

%lsaf_uploadandexpand(local_path=, lsaf_path=, lsaf_enableversioning=, lsaf_versiontype=, lsaf_customversion=, lsaf_comment=);

[ Exposure: external ]
Uploads and expands the contents of a ZIP file into the specified folder location in the SAS
Life Science Analytics Framework repository.

NOTE: This macro is supported only from a PC SAS session. Using this macro within an active
SAS Life Science Analytics Framework application session results in a failure.

Failure and Message Handling

The action status for each file that is uploaded and each folder that is created is printed
in the SAS log file.

Syntax:
%LSAF_UPLOADANDEXPAND(LOCAL_PATH=local-zipfile-path, LSAF_PATH=lsaf-path
<, LSAF_ENABLEVERSIONING=lsaf-enable-versioning, LSAF_VERSIONTYPE=lsaf-version-type,
LSAF_VERSIONTYPE=lsaf_customversion, LSAF_COMMENT=lsaf_comment>);

          
History:
   2013-03-18
initial code
   2016-08-26
rebrand as LSAF
   2018-01-09
updates to for LSAF 5.1
   2020-11-18
updated for version handling.
Expected Macro Variables:
_lsafMsg_ - The return message.
_lsafRC_ - The return code.
Parameters:
local_path - - Required - The absolute path and name of the ZIP file on the local
        computer.
lsaf_path - - Required - The path of the target folder.
lsaf_enableversioning - - Optional - Indicates whether the new files to be create are
        versioned. Valid values:
        - 0 (Default): Create non-versioned files.
        - 1: Create versioned files.
        The versioning status of existing files is not changed.
lsaf_versiontype - - Optional - The case insensitive type for a versioned file. This
        parameter will not apply if the file exists as a non-versioned file. If not provided, the
        system defaults will be applied.
        Valid values: MAJOR, MINOR, or CUSTOM.
lsaf_customversion - - Conditional - Sets the specified version value if lsaf_versiontype
        is CUSTOM. This parameter will not apply if the file exists as a non-versioned file.
lsaf_comment - - Optional - The comment associated with the new file or file version.
File: lsaf_uploadandexpand.sas
First available in version: 1.4