source: WorldVistAEHR/trunk/r/SPINAL_CORD_DYSFUNCTION-SPN/SPNLGU.m@ 1432

Last change on this file since 1432 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 832 bytes
Line 
1SPNLGU ; ISC-SF/GMB - SCD LOCAL GATHER UTILITIES;11 MAY 94 [07/12/94]
2 ;;2.0;Spinal Cord Dysfunction;**24**;01/02/1997
3TRANSLAT(Y,FILENUM,FIELDNUM) ; Translate set of codes to clear text meaning
4 N C
5 S C=$P(^DD(FILENUM,FIELDNUM,0),U,2)
6 D Y^DIQ
7 Q Y
8STOPCODE(CLINIC) ; follow clinic ptr to hospital loc to stop code num
9 D SRAPI
10 Q $G(SPNSTPCD)
11SRAPI ;
12 S SDARRAY(1)=FDATE_";"_TDATE
13 S SDARRAY(2)=+CLINIC
14 S SDARRAY(3)="R;I"
15 S SDARRAY("FLDS")=13
16 S SDDATE=$P(APPTINFO,U,1)
17 S SDCOUNT=$$SDAPI^SDAMA301(.SDARRAY)
18 I SDCOUNT<0 D
19 .I $D(^TMP($J,"SDAMA301",101)) W !!,"Database unavailable. Try later."
20 .I $D(^TMP($J,"SDAMA301",116)) W !!,"Pt doesn't exit in Vista system."
21 .Q
22 S SPNSTPCD=$P(^TMP($J,"SDAMA301",+CLINIC,DFN,SDDATE),U,13)
23 S SPNSTPCD=$P(SPNSTPCD,";",2)
24 I SDCOUNT'=0 K ^TMP($J,"SDAMA301")
25 K SDARRAY,SDCOUNT,SDDATE
26 Q
Note: See TracBrowser for help on using the repository browser.