DGRRPSD3 ; ALB/SGG - rtnDGRR PatientServices Demographics Tertiary ;09/30/03 ; Compiled November 4, 2003 12:01:00
;;5.3;Registration;**557**;Aug 13, 1993
;
;
DOC ;"
DO ALISINFO
SET CNT=$G(CNT)+1,PSARRAY(CNT)=""_"^^^1"
QUIT
;
LAST() QUIT $P(GLOB("NAME"),"^",1)
;
FIRST() QUIT $P(GLOB("NAME"),"^",2)
;
MIDDLE() QUIT $P(GLOB("NAME"),"^",3)
;
PREFIX() QUIT $P(GLOB("NAME"),"^",5)
;
SUFFIX() QUIT $P(GLOB("NAME"),"^",4)
;
DEGREE() QUIT $P(GLOB("NAME"),"^",6)
;
CITYOB() QUIT $P(GLOB(0),"^",11)
;
STATEOB() ;
NEW DATA
SET DATA=$P(GLOB(0),"^",12)
IF DATA'="" SET DATA=$P($G(^DIC(5,DATA,0)),"^",2)
QUIT DATA
;
ENTBYWHO() ;
NEW DATA
SET DATA=$P(GLOB(0),"^",15)
IF DATA'="" SET DATA=$P($G(^VA(200,DATA,0)),"^",1)
QUIT DATA
;
WHOVPID() ;
QUIT $$VPID^XUPS($P(GLOB(0),"^",15))
;
ENTDATE() QUIT $P(GLOB(0),"^",16)
;
DADNAME() QUIT $P(GLOB(.24),"^",1)
;
MOMNAME() QUIT $P(GLOB(.24),"^",2)
;
MADNAME() QUIT $P(GLOB(.24),"^",3)
;
OCCUPAT() QUIT $P(GLOB(0),"^",7)
;
MULTIBI() ;
NEW DATA
SET DATA=$P($G(^DPT(PTID,"MPIMB")),"^",1)
SET DATA=$S(DATA="Y":"YES",DATA="N":"NO",1:"")
QUIT DATA
;
ALISINFO ;
NEW ALISCNT,ROWCNT,ALIS,ALISSSN
SET ALISCNT=0,ROWCNT=0
FOR SET ALISCNT=$O(^DPT(PTID,.01,ALISCNT)) QUIT:(ALISCNT<1) DO
.SET ALIS=$P($G(^DPT(PTID,.01,ALISCNT,0)),"^",1)
.SET ALISSSN=$P($G(^DPT(PTID,.01,ALISCNT,0)),"^",2)
.IF +$L(ALIS_ALISSSN) DO
..SET ROWCNT=ROWCNT+1
..SET CNT=$G(CNT)+1,PSARRAY(CNT)=""
IF ROWCNT=0 DO
.SET CNT=$G(CNT)+1,PSARRAY(CNT)=""
QUIT