The CDISC-SOURCE to
CRT-DDS transformation operates on saved data so that SAS programmers
who are familiar with the table model representation for CRT-DDS can
add customizations to a define.xml file. This is a two-step process:
-
Insert custom study metadata into the saved CRT-DDS
tables.
-
Generate a customized define.xml file from these updated
tables.
Here is example code
that creates a define.xml file from saved data. Edit this example
code to point to the location of the customized tables.
%let SASCrtddsTables = %nrquote(\\myCDIServer\mydatatables);
%let DefPath = %nrquote(\\myCDIServer\myDefineLocation);
%let DefFile = %nrquote(define.xml);
%cst_setStandardProperties(_cstStandard=CST-FRAMEWORK,_cstSubType=initialize);
%cst_setStandardProperties(_cstStandard=CDISC-CRTDDS,_cstSubType=initialize);
%let workPath=%sysfunc(pathname(work));
%let _cstSASRefs=work.sasreferences;
%let _cstSASRefsLoc=&workpath;
%let _cstSASRefsName=sasreferences;
%let _cstResultsds=crtdds_results;
%cst_createdsfromtemplate(_cstStandard=CST-FRAMEWORK, _cstType=control,_cstSubType=reference, _cstOutputDS=work.sasreferences);
%LET _CSTSTANDARD=CDISC-CRTDDS;
%LET _CSTSTANDARDVERSION=1.0;
proc sql;
insert into work.sasreferences
values ("CST-FRAMEWORK" "1.2" "messages" "" "messages" "libref" "input" "dataset"
"N" "" "" 1 "" "")
values ("&_cstStandard" "&_cstStandardVersion" "messages" "" "crtmsg" "libref" "input" "dataset"
"N" "" "" 2 "" "")
values ("&_cstStandard" "&_cstStandardVersion" "autocall" "" "auto1" "fileref" "input" "folder" "
N" "" "" 1 "" "")
values ("&_cstStandard" "&_cstStandardVersion" "control" "reference" "control" "libref" "both" "dataset"
"Y" "" "&workpath" . "sasreferences" "")
values ("&_cstStandard" "&_cstStandardVersion" "sourcedata" "" "srcdata" "libref" "input" "folder"
"N" "" "&SASCrtddsTables" . "" "")
values ("&_cstStandard" "&_cstStandardVersion" "externalxml" "xml" "extxml" "fileref" "output" "file"
"Y" "" "&defpath" . "&deffile" "")
values ("&_cstStandard" "&_cstStandardVersion" "referencexml" "stylesheet" "xslt01" "fileref" "output" "file" "
Y" "" "" . "" "")
;
quit;
%let _cstReallocateSasrefs=1;
%cstutil_allocatesasreferences;
%crtdds_write(_cstCreateDisplayStyleSheet=1,_cstResultsOverrideDS=&_cstResultsDS);
In the example code,
edit SASCrtddsTables to specify the location where the saved data
sets exist, and edit DefPath to specify the location to write the
resulting define.xml file.
Note: If you are viewing an electronic
version of this document, you can cut and paste the example code.