/*------------------------------------------------------------*
* program:     cdisc38.sas                                    *
* Description: Case #38. Dose Null For Interventions domains, this identifies records that violate the condition *
*              [Dose greater than or equal to 0], limited to records where [Dose is not null].*
* By:          Sy Truong, 10/14/2009                          *
*-------------------------------------------------------------*/
 
libname templib '../data';

*** Create some data to be selected ***;
data templib.ex(label="Exposure");
attrib STUDYID	label="Study Identifier" length=$100;
attrib DOMAIN	label="Domain Abbreviation" length=$100;
attrib USUBJID	label="Unique Subject Identifier" length=$100;
attrib EXSEQ	label="Sequence Number" length=8;
attrib EXGRPID	label="Group ID" length=$100;
attrib EXSPID	label="Sponsor-Defined Identifier" length=$100;
attrib EXTRT	label="Name of Actual Treatment" length=$100;
attrib EXCAT	label="Category for Treatment" length=$100;
attrib EXSCAT	label="Subcategory for Treatment" length=$100;
attrib EXDOSE	label="Dose per Administration" length=8;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=0;
output;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=1;
output;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=2;
output;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=-6;
output;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=4;
output;
STUDYID='test';DOMAIN='test';USUBJID='test';EXSEQ=1;EXGRPID='test';EXSPID='test';EXTRT='test';EXCAT='test';EXSCAT='test';EXDOSE=.;
output;


run;
%cdisc(datlib=templib,datname=ex);
