Module DictionaryService

Macros to get and export dictionary information in SAS Life Science Analytics Framework.

Since: 2.1

Macro Summary
external

LSAF
%lsaf_exportdictionary(lsaf_dictionaryid=, lsaf_status=, lsaf_dictionaryversion=, lsaf_location=, lsaf_path=, lsaf_overwrite=, lsaf_enableversioning=, lsaf_versiontype=, lsaf_customversion=, lsaf_comment=);
Exports the metadata for a controlled terminology dictionary. The metadata is stored in a SAS ...
external

LSAF
%lsaf_getdictionariesbystatus(lsaf_status=, sas_dsname=work.lsafgetdictionariesbystatus);
Gets the metadata for all of the dictionaries by the specified status. The metadata is stored in ...
external

LSAF
%lsaf_getdictionaryid(lsaf_name=, lsaf_status=);
Gets the dictionary identifer for a controlled terminology dictionary. The SAS macro variable ...

Macro Detail

%lsaf_exportdictionary(lsaf_dictionaryid=, lsaf_status=, lsaf_dictionaryversion=, lsaf_location=, lsaf_path=, lsaf_overwrite=, lsaf_enableversioning=, lsaf_versiontype=, lsaf_customversion=, lsaf_comment=);

[ Exposure: external ]
Exports the metadata for a controlled terminology dictionary. The metadata is stored in a SAS
data set based on the specified location (WORKSPACE or REPOSITORY).

Syntax:
%LSAF_EXPORTDICTIONARY(LSAF_DICTIONARYID=lsaf-dictionaryid,
LSAF_STATUS=lsaf-status,
LSAF_DICTIONARYVERSION=lsaf-dictionaryversion,
LSAF_LOCATION=lsaf-location,
LSAF_PATH=lsaf-path,
LSAF_OVERWRITE=lsaf-overwrite,
LSAF_ENABLEVERSIONING=lsaf-enableversioning,
LSAF_VERSIONTYPE=lsaf-versiontype,
LSAF_CUSTOMVERSION=lsaf-customversion,
LSAF_COMMENT=lsaf-comment);

          
History:
   2019-06-27
initial coding
   2020-07-14
update for refactor of java service hierarchy.
   2020-11-23
update for versioning strategy.
Expected Macro Variables:
_lsafDictionaryPath_ - The full path of the dictionary data set, which includes the file
        extension. If the dictionary data set is not created, _lsafDictionaryPath_ is blank.
_lsafMsg_ - The return message.
_lsafRC_ - The return code.
Parameters:
lsaf_dictionaryid - - Required - The identifier of the dictionary. The identifier can be
        retrieved by calling the lsaf_getdictionaryid macro.
lsaf_status - - Required - The status of the dictionary. Valid values: PUBLISHED,
        INPROGRESS, and CHECKEDOUT. The default value is PUBLISHED.
lsaf_dictionaryversion - - Optional - The version of a PUBLISHED dictionary to export. A
        blank value returns the latest version. This option is ignored if the status is not PUBLISHED.
lsaf_location - - Required - The case-insensitive output location for the dictionary file.
        Valid values: WORKPSACE and REPOSITORY.
lsaf_path - - Required - The output path for the dictionary file. If the file extension is
        not specified, it is added during processing.
lsaf_overwrite - - Optional - Indicates whether an existing unversioned repository or
        existing workspace exported file will be overwritten by the file with a same path.
        When a versioned repository file already exists, this parameter is ignored and the
        parameters versionType and customVersion, or their defaults if not specified, are
        applied to the new version of the file.
        Valid values: 0 = No (Default), 1 = Yes.
lsaf_enableversioning - - Optional - Indicates whether a new exported file is versioned.
        Ignored if lsaf_location=WORKSPACE. Valid values: 0 (Default): No, 1: Yes
lsaf_versiontype - - Optional - The case insensitive type for a versioned file
        in the repository. This parameter is ignored when writing to the workspace and will
        not apply if the file exists as a non-versioned repository 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 is ignored when writing to the workspace and will not apply if the
        file exists as a non-versioned repository file.
lsaf_comment - - Optional - The check-in comment to associate with the action of adding the
        data set to the repository. This option is ignored if lsaf_location=WORKSPACE.
File: lsaf_exportdictionary.sas
First available in version: 2.2

%lsaf_getdictionariesbystatus(lsaf_status=, sas_dsname=work.lsafgetdictionariesbystatus);

[ Exposure: external ]
Gets the metadata for all of the dictionaries by the specified status. The metadata is stored in
a SAS data set.

Syntax:
%LSAF_GETDICTIONARIESBYSTATUS(LSAF_STATUS=lsaf-status,
<SAS_DSNAME=WORK.LSAFGETDICTIOANRIESBYSTATUS>);

          
History:
   2019-06-25
initial coding
   2019-11-01
update to handle a blank SAS output file.
   2020-07-14
update for refactor of java service hierarchy.
Expected Macro Variables:
_lsafMsg_ - The return message.
_lsafRC_ - The return code.
Parameters:
lsaf_status - - Required - The status of the dictionaries to return.
        Valid values: PUBLISHED, INPROGRESS, and CHECKEDOUT. The default value is PUBLISHED.
sas_dsname - - Optional - The name of the output SAS data set to contain the metadata
        for the dictionaries, specified as libref.dataset. The default value is
        WORK.LSAFGETDICTIONARIESBYSTATUS. The data set contains a row for each dictionary,
        sorted by the dictionary ID, and columns with the following names:
        - id: The unique dictionary identifier.
        - name: The dictionary name.
        - standard: The associated data standard.
        - description: The dictionary description.
        - isCheckedOut: Indicates whether the dictionary is checked out. Valid values:
        0: no, 1: yes.
        - checkedOutBy: The identifier of the user who has the dictionary checked out, if it
        is checked out. This should always be the identifier of the current user.
        - checkedOutDate: The date on which the dictionary was checked out, if it is checked
        out.
        - checkedOutDateSASFormat: The date on which the dictionary was checked out (SAS
        Format), if it is checked out.
        - createdDate: The date on which the dictionary was created.
        - createdDateSASFormat: The date on which the dictionary was created (in SAS Format).
        - createdBy: The identifier of the user who created the dictionary.
        - state: The state of the dictionary.
        - publishedState: The published state of the dictionary.
        - currentVersion: The current published version of the dictionary.
        - associatedStudiesCount: The number of studies that are associated with the
        dictionary.
        - lastModifiedDate: The date on which the dictionary was last modified.
        - lastModifiedDateSASFormat: The date on which the dictionary was last modified (in
        SAS Format).
        - lastModifiedBy: The identifier of the user of who last modified the dictionary.
        - releaseDate: The date on which the dictionary was released.
        - dictionaryStatus: The status of the dictionary.
File: lsaf_getdictionariesbystatus.sas
First available in version: 2.2

%lsaf_getdictionaryid(lsaf_name=, lsaf_status=);

[ Exposure: external ]
Gets the dictionary identifer for a controlled terminology dictionary. The SAS macro variable
_lsafDictionaryId_ is set to the identifer.

Syntax:
%LSAF_GETDICTIONARYID(LSAF_NAME=lsaf-name, LSAF_STATUS=lsaf-status);

          
History:
   2019-07-23
Initial coding
   2020-07-14
update for refactor of java service hierarchy.
Expected Macro Variables:
_lsafDictionaryId_ - The dictionary identifer.
_lsafMsg_ - The return message.
_lsafRC_ - The return code.
Parameters:
lsaf_name - - Required - The case-sensitive name of the dictionary.
lsaf_status - - Optional - The status of the dictionary. The default is PUBLISHED.
        Valid values: PUBLISHED, INPROGRESS, CHECKEDOUT.
File: lsaf_getdictionaryid.sas
First available in version: 2.2