source: FOIAVistA/trunk/r/MEDICINE-MC/MCARAM0B.m@ 1354

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

initial load of FOIAVistA 6/30/08 version

File size: 810 bytes
Line 
1MCARAM0B ;WASH ISC/JKL-MUSE AUTO INSTRUMENT REINIT-TRAN CORRES EKG ;2/24/95 10:50
2 ;;2.3;Medicine;;09/13/1996
3 ;
4 ;
5 ; Called from ^MCARAM0
6 ; Deletes EKG records without corresponding dated transaction records
7 ; Deletes Error Summary records without corresponding dated EKG records
8 N MCNAME,MCSSN,MCDATE,MCIEN,MCROOT,DA,DIK
9 S (MCIEN,MCDATE)=0
10 S MCROOT="^MCAR(691.5,"
11 F S MCDATE=$O(^MCAR(691.5,"B",MCDATE)) Q:MCDATE="" S MCIEN=0 F S MCIEN=$O(^MCAR(691.5,"B",MCDATE,MCIEN)) Q:MCIEN="" I '$D(^MCAR(700.5,"B",MCDATE)) D DEL
12 S MCROOT="^MCAR(700.5,",MCDATE=0,MCIEN=0
13 F S MCDATE=$O(^MCAR(700.5,"B",MCDATE)) Q:MCDATE="" S MCIEN=0 F S MCIEN=$O(^MCAR(700.5,"B",MCDATE,MCIEN)) Q:MCIEN="" I '$D(^MCAR(691.5,"B",MCDATE)) D DEL
14 Q
15DEL ;
16 S MCCNT=MCCNT+1
17 S DIK=MCROOT,DA=MCIEN D ^DIK
18 W:MCCNT#100=0 "."
19 Q
Note: See TracBrowser for help on using the repository browser.