DGPT101P ;ALB/MTC,HIOFO/FT - Parse 101 record ;12/8/2014 1:22pm
;;5.3;Registration;**164,678,664,884**;Aug 13, 1993;Build 31
;;
SET ; Parse 101 record
D:DGPTFMT=2 SET9
D:DGPTFMT=3 SET10
Q
SET9 ;record layout before icd10 turned on
S DGPTDTS=$$FMDT^DGPT101($E(DGPTSTR,15,20))_"."_$E(DGPTSTR,21,24)
S DGPTPS=$E(DGPTSTR,5) ;pseudo ssn
S DGPTSSN=$E(DGPTSTR,6,14) ;social security number
S DGPTDTA=$E(DGPTSTR,15,24) ;admission date (mmddyy) and time (2400 clock)
S DGPTFAC=$E(DGPTSTR,25,30) ;facility number and suffix
S DGPTLN=$E(DGPTSTR,31,42) ;patient's last name
S DGPTFI=$E(DGPTSTR,43) ;patient's first initial
S DGPTMI=$E(DGPTSTR,44) ;patient's middle initial
S DGPTSRA=$E(DGPTSTR,45,46) ;source of admission
S DGPTTF=$E(DGPTSTR,47,52) ;transferring facility & suffix
S DGPTSRP=$E(DGPTSTR,53) ;source of payment
S DGPTPOW=$E(DGPTSTR,54) ;prisoner of war
S DGPTMRS=$E(DGPTSTR,55) ;marital status
S DGPTGEN=$E(DGPTSTR,56) ;sex indicator
S DGPTDOB=$E(DGPTSTR,57,64) ;date of birth
;S DGPTBY=$E(DGPTSTR,61,64) ;year of birth <-not used. DGPT10CB sets DGPTBYR instead. ft 11/3/14
S DGPTPOS1=$E(DGPTSTR,65) ;space, not used
S DGPTPOS2=$E(DGPTSTR,66) ;period of service indicator
S DGPTEXA=$E(DGPTSTR,67) ;agent orange indicator
S DGPTEXI=$E(DGPTSTR,68) ;ionizing radiation indicator
S DGPTSTE=$E(DGPTSTR,69,70) ;state of residence indicator
S DGPTCTY=$E(DGPTSTR,71,73) ;county of residence indicator
S DGPTZIP=$E(DGPTSTR,74,78) ;zip code
S DGPTMTC=$E(DGPTSTR,79,80) ;means test indicator
S DGPTINC=$E(DGPTSTR,81,86) ;income
S DGPTERI=$E(DGPTSTR,96) ;emergency response indicator
S DGPTCTRY=$E(DGPTSTR,97,99) ;country code
Q
SET10 ;record layout after icd10 turned on
S DGPTDTS=$$FMDT^DGPT101($E(DGPTSTR,15,20))_"."_$E(DGPTSTR,21,24)
S DGPTPS=$E(DGPTSTR,5) ;pseudo ssn
S DGPTSSN=$E(DGPTSTR,6,14) ;social security number
S DGPTDTA=$E(DGPTSTR,15,24) ;admission date (mmddyy) and time (2400 clock)
S DGPTFAC=$E(DGPTSTR,25,30) ;facility number and suffix
S DGPTLN=$E(DGPTSTR,31,42) ;patient's last name
S DGPTFI=$E(DGPTSTR,43) ;patient's first initial
S DGPTMI=$E(DGPTSTR,44) ;patient's middle initial
S DGPTSRA=$E(DGPTSTR,45,46) ;source of admission
S DGPTTF=$E(DGPTSTR,47,52) ;transferring facility & suffix
S DGPTSRP=$E(DGPTSTR,53) ;source of payment
S DGPTPOW=$E(DGPTSTR,54) ;prisoner of war
S DGPTMRS=$E(DGPTSTR,55) ;marital status
S DGPTGEN=$E(DGPTSTR,56) ;sex indicator
S DGPTDOB=$E(DGPTSTR,57,64) ;date of birth
S DGPTPOS1=$E(DGPTSTR,65) ;space, not used
S DGPTPOS2=$E(DGPTSTR,66) ;period of service indicator
S DGPTEXA=$E(DGPTSTR,67) ;agent orange indicator
S DGPTEXI=$E(DGPTSTR,68) ;ionizing radiation indicator
S DGPTSTE=$E(DGPTSTR,69,70) ;state of residence indicator
S DGPTCTY=$E(DGPTSTR,71,73) ;county of residence indicator
S DGPTZIP=$E(DGPTSTR,74,78) ;zip code
S DGPTMTC=$E(DGPTSTR,79,80) ;means test indicator
S DGPTINC=$E(DGPTSTR,81,86) ;income
S DGPTMST=$E(DGPTSTR,87) ;military sexual trauma
S DGPTCOMVET=$E(DGPTSTR,88) ;combat vet
S DGPTCOMVETDT=$E(DGPTSTR,89,94) ;combat vet date mmddyy
S DGPTSHAD=$E(DGPTSTR,95) ;shad indicator
S DGPTERI=$E(DGPTSTR,96) ;emergency response indicator
S DGPTCTRY=$E(DGPTSTR,97,99) ;country code
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HDGPT101P 3273 printed Dec 13, 2024@02:51:14 Page 2
DGPT101P ;ALB/MTC,HIOFO/FT - Parse 101 record ;12/8/2014 1:22pm
+1 ;;5.3;Registration;**164,678,664,884**;Aug 13, 1993;Build 31
+2 ;;
SET ; Parse 101 record
+1 if DGPTFMT=2
DO SET9
+2 if DGPTFMT=3
DO SET10
+3 QUIT
SET9 ;record layout before icd10 turned on
+1 SET DGPTDTS=$$FMDT^DGPT101($EXTRACT(DGPTSTR,15,20))_"."_$EXTRACT(DGPTSTR,21,24)
+2 ;pseudo ssn
SET DGPTPS=$EXTRACT(DGPTSTR,5)
+3 ;social security number
SET DGPTSSN=$EXTRACT(DGPTSTR,6,14)
+4 ;admission date (mmddyy) and time (2400 clock)
SET DGPTDTA=$EXTRACT(DGPTSTR,15,24)
+5 ;facility number and suffix
SET DGPTFAC=$EXTRACT(DGPTSTR,25,30)
+6 ;patient's last name
SET DGPTLN=$EXTRACT(DGPTSTR,31,42)
+7 ;patient's first initial
SET DGPTFI=$EXTRACT(DGPTSTR,43)
+8 ;patient's middle initial
SET DGPTMI=$EXTRACT(DGPTSTR,44)
+9 ;source of admission
SET DGPTSRA=$EXTRACT(DGPTSTR,45,46)
+10 ;transferring facility & suffix
SET DGPTTF=$EXTRACT(DGPTSTR,47,52)
+11 ;source of payment
SET DGPTSRP=$EXTRACT(DGPTSTR,53)
+12 ;prisoner of war
SET DGPTPOW=$EXTRACT(DGPTSTR,54)
+13 ;marital status
SET DGPTMRS=$EXTRACT(DGPTSTR,55)
+14 ;sex indicator
SET DGPTGEN=$EXTRACT(DGPTSTR,56)
+15 ;date of birth
SET DGPTDOB=$EXTRACT(DGPTSTR,57,64)
+16 ;S DGPTBY=$E(DGPTSTR,61,64) ;year of birth <-not used. DGPT10CB sets DGPTBYR instead. ft 11/3/14
+17 ;space, not used
SET DGPTPOS1=$EXTRACT(DGPTSTR,65)
+18 ;period of service indicator
SET DGPTPOS2=$EXTRACT(DGPTSTR,66)
+19 ;agent orange indicator
SET DGPTEXA=$EXTRACT(DGPTSTR,67)
+20 ;ionizing radiation indicator
SET DGPTEXI=$EXTRACT(DGPTSTR,68)
+21 ;state of residence indicator
SET DGPTSTE=$EXTRACT(DGPTSTR,69,70)
+22 ;county of residence indicator
SET DGPTCTY=$EXTRACT(DGPTSTR,71,73)
+23 ;zip code
SET DGPTZIP=$EXTRACT(DGPTSTR,74,78)
+24 ;means test indicator
SET DGPTMTC=$EXTRACT(DGPTSTR,79,80)
+25 ;income
SET DGPTINC=$EXTRACT(DGPTSTR,81,86)
+26 ;emergency response indicator
SET DGPTERI=$EXTRACT(DGPTSTR,96)
+27 ;country code
SET DGPTCTRY=$EXTRACT(DGPTSTR,97,99)
+28 QUIT
SET10 ;record layout after icd10 turned on
+1 SET DGPTDTS=$$FMDT^DGPT101($EXTRACT(DGPTSTR,15,20))_"."_$EXTRACT(DGPTSTR,21,24)
+2 ;pseudo ssn
SET DGPTPS=$EXTRACT(DGPTSTR,5)
+3 ;social security number
SET DGPTSSN=$EXTRACT(DGPTSTR,6,14)
+4 ;admission date (mmddyy) and time (2400 clock)
SET DGPTDTA=$EXTRACT(DGPTSTR,15,24)
+5 ;facility number and suffix
SET DGPTFAC=$EXTRACT(DGPTSTR,25,30)
+6 ;patient's last name
SET DGPTLN=$EXTRACT(DGPTSTR,31,42)
+7 ;patient's first initial
SET DGPTFI=$EXTRACT(DGPTSTR,43)
+8 ;patient's middle initial
SET DGPTMI=$EXTRACT(DGPTSTR,44)
+9 ;source of admission
SET DGPTSRA=$EXTRACT(DGPTSTR,45,46)
+10 ;transferring facility & suffix
SET DGPTTF=$EXTRACT(DGPTSTR,47,52)
+11 ;source of payment
SET DGPTSRP=$EXTRACT(DGPTSTR,53)
+12 ;prisoner of war
SET DGPTPOW=$EXTRACT(DGPTSTR,54)
+13 ;marital status
SET DGPTMRS=$EXTRACT(DGPTSTR,55)
+14 ;sex indicator
SET DGPTGEN=$EXTRACT(DGPTSTR,56)
+15 ;date of birth
SET DGPTDOB=$EXTRACT(DGPTSTR,57,64)
+16 ;space, not used
SET DGPTPOS1=$EXTRACT(DGPTSTR,65)
+17 ;period of service indicator
SET DGPTPOS2=$EXTRACT(DGPTSTR,66)
+18 ;agent orange indicator
SET DGPTEXA=$EXTRACT(DGPTSTR,67)
+19 ;ionizing radiation indicator
SET DGPTEXI=$EXTRACT(DGPTSTR,68)
+20 ;state of residence indicator
SET DGPTSTE=$EXTRACT(DGPTSTR,69,70)
+21 ;county of residence indicator
SET DGPTCTY=$EXTRACT(DGPTSTR,71,73)
+22 ;zip code
SET DGPTZIP=$EXTRACT(DGPTSTR,74,78)
+23 ;means test indicator
SET DGPTMTC=$EXTRACT(DGPTSTR,79,80)
+24 ;income
SET DGPTINC=$EXTRACT(DGPTSTR,81,86)
+25 ;military sexual trauma
SET DGPTMST=$EXTRACT(DGPTSTR,87)
+26 ;combat vet
SET DGPTCOMVET=$EXTRACT(DGPTSTR,88)
+27 ;combat vet date mmddyy
SET DGPTCOMVETDT=$EXTRACT(DGPTSTR,89,94)
+28 ;shad indicator
SET DGPTSHAD=$EXTRACT(DGPTSTR,95)
+29 ;emergency response indicator
SET DGPTERI=$EXTRACT(DGPTSTR,96)
+30 ;country code
SET DGPTCTRY=$EXTRACT(DGPTSTR,97,99)
+31 QUIT