Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: BCHFC1

BCHFC1.m

Go to the documentation of this file.
BCHFC1 ; IHS/CMI/LAB - FORMS COUNT (FILE) report process ; 
 ;;2.0;IHS RPMS CHR SYSTEM;;OCT 23, 2012;Build 27
 ;IHS/CMI/LAB - tmp to xtmp
P ; Run by posting date
 S BCHH=$H,BCHJOB=$J
 S BCHODAT=BCHSD_".9999" F  S BCHODAT=$O(^BCHR("AD",BCHODAT)) Q:BCHODAT=""!((BCHODAT\1)>BCHED)  D V1
 S BCHET=$H
 D EOJ
 Q
V1 ;
 S BCHVSIT="" F  S BCHVSIT=$O(^BCHR("AD",BCHODAT,BCHVSIT)) Q:BCHVSIT'=+BCHVSIT  I $D(^BCHR(BCHVSIT,0)) D PROC
 Q
PROC ;
 I BCHDEC'="ALL",BCHDEC'=$P(^BCHR(BCHVSIT,0),U,16) Q
 Q:$P(^BCHR(BCHVSIT,0),U,16)=""
 Q:'$D(^VA(200,$P(^BCHR(BCHVSIT,0),U,16),0))
 S BCHAP=$P(^VA(200,$P(^BCHR(BCHVSIT,0),U,16),0),U)
 S BCHVREC=^BCHR(BCHVSIT,0)
 S BCHDATE=$P(BCHODAT,".")
SET S ^(BCHDATE)=$S($D(^XTMP("BCHFC",BCHJOB,BCHH,BCHAP,BCHDATE)):^(BCHDATE)+1,1:1)
 Q
EOJ ; clean up and exit
 K BCHVREC,BCHCLIN,BCHSKIP,BCH1,BCH2,BCHAP,BCHX,BCHY,BCHVDES,BCHDATE,BCHPROV,BCHSEC,BCHZ
 Q
 ;
 ;