ICDREF ;ALB/EG/KUM - GROUPER UTILITY FUNCTIONS ;5/20/05 8:35pm
;;18.0;DRG Grouper;**14,17,57,64**;Oct 20, 2000;Build 103
;
RTABLE(ICDRG,ICDDATE) ; Return Reference Table
; Input: ICDRG - DRG entry
; ICDDATE - Date to use for resolving correct entry
;
; Output: Table reference associted with entry from DRG
; file
Q $$REF^ICDEX($G(ICDRG),$G(ICDDATE))
VMDC(IEN) ;Get versioned MDC for Diagnosis Code
Q $$VMDCDX^ICDEX($G(IEN),$G(ICDDATE))
;
GETPVMDC ;Get versioned MDC for Op/Pro ICD code from previous years
; Needs CODE, ICDMDC and DRGFY
S X=$$VMDCOP^ICDEX(+($G(CODE)),$G(ICDMDC),$G(DRGFY))
S DRGFY=$P(X,"^",1),ICDMDC=$P(X,"^",2),DADRGFY=$P(X,"^",3),DAMDC=$P(X,"^",4)
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HICDREF 739 printed Oct 16, 2024@17:51:41 Page 2
ICDREF ;ALB/EG/KUM - GROUPER UTILITY FUNCTIONS ;5/20/05 8:35pm
+1 ;;18.0;DRG Grouper;**14,17,57,64**;Oct 20, 2000;Build 103
+2 ;
RTABLE(ICDRG,ICDDATE) ; Return Reference Table
+1 ; Input: ICDRG - DRG entry
+2 ; ICDDATE - Date to use for resolving correct entry
+3 ;
+4 ; Output: Table reference associted with entry from DRG
+5 ; file
+6 QUIT $$REF^ICDEX($GET(ICDRG),$GET(ICDDATE))
VMDC(IEN) ;Get versioned MDC for Diagnosis Code
+1 QUIT $$VMDCDX^ICDEX($GET(IEN),$GET(ICDDATE))
+2 ;
GETPVMDC ;Get versioned MDC for Op/Pro ICD code from previous years
+1 ; Needs CODE, ICDMDC and DRGFY
+2 SET X=$$VMDCOP^ICDEX(+($GET(CODE)),$GET(ICDMDC),$GET(DRGFY))
+3 SET DRGFY=$PIECE(X,"^",1)
SET ICDMDC=$PIECE(X,"^",2)
SET DADRGFY=$PIECE(X,"^",3)
SET DAMDC=$PIECE(X,"^",4)
+4 QUIT