source: FOIAVistA/trunk/r/GEN_MED_REC_GENERATOR-GMRG/GMRGXUPD.m@ 1800

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

initial load of FOIAVistA 6/30/08 version

File size: 1.4 KB
Line 
1GMRGXUPD ;HIRMFO/RM-POST BUILD TASKS FOR PATCH GMRG*3.0*1 ;4/11/96
2 ;;3.0;Text Generator;**1**;Jan 24, 1996
3EN1 ; ENTRY FROM BUILD TO PERFORM POST BUILD TASKS
4 D KILLDD,SET6
5 Q
6KILLDD ; KILL BAD ^DD NODES FROM AGGREGATE TERM (124.2) FILE. SEE DBIA
7 ; #1412, WHICH AUTHORIZES THIS DD KILL.
8 K ^DD(124.2,0,"DIK"),^DD(124.2,0,"DIKOLD"),^DD(124.21,0,"DIK")
9 Q
10SET6 ; LOOP THROUGH GMR TEXT (124.3) FILE ENTRIES AND SET THE DATE LAST
11 ; UPDATED (6) FIELD TO LATEST DATE IN AUDIT TRAIL MULTIPLE.
12 N DA,DIE,DR,GMRGAUD,GMRGLAUD,GMRGSEL,GMRGDOT,X
13 D BMES^XPDUTL("Populating the Date Last Updated (6) field of the GMR Text (124.3) file...")
14 S DA=0 F S DA=$O(^GMR(124.3,DA)) Q:DA'>0 D
15 . S GMRGLAUD=$P($G(^GMR(124.3,DA,0)),"^",3)
16 . S GMRGSEL=0 F S GMRGSEL=$O(^GMR(124.3,DA,1,GMRGSEL)) Q:GMRGSEL'>0 D
17 . . S GMRGAUD=0 F S GMRGAUD=$O(^GMR(124.3,DA,1,GMRGSEL,2,GMRGAUD)) Q:GMRGAUD'>0 D
18 . . . S X=$P($G(^GMR(124.3,DA,1,GMRGSEL,2,GMRGAUD,0)),"^")
19 . . . I X>GMRGLAUD S GMRGLAUD=X
20 . . . Q
21 . . Q
22 . I GMRGLAUD S DIE="^GMR(124.3,",DR="6////"_GMRGLAUD D ^DIE W:'$R(100) "."
23 . Q
24 D BMES^XPDUTL(" ")
25 D BMES^XPDUTL("Re-indexing ""AC"" cross-refence in Children multiple...")
26 K DA S DA(1)=0 F S DA(1)=$O(^GMRD(124.2,DA(1))) Q:DA(1)'>0 D
27 . K ^GMRD(124.2,DA(1),1,"AC")
28 . S DA=0 F S DA=$O(^GMRD(124.2,DA(1),1,DA)) Q:DA'>0 D
29 . . S DIK="^GMRD(124.2,"_DA(1)_",1,",DIK(1)="1^AC" D EN1^DIK
30 . . Q
31 . W:'$R(50) "."
32 . Q
33 Q
Note: See TracBrowser for help on using the repository browser.