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

DITMGM2.m

Go to the documentation of this file.
DITMGM2 ;SFISC/EDE(OHPRD)-GENERAL RELINK/MERGE ;2015-01-02  5:09 PM
 ;;22.2;VA FileMan;;Jan 05, 2016;Build 42
 ;;Per VA Directive 6402, this routine should not be modified.
 ;;Submitted to OSEHRA 5 January 2015 by the VISTA Expertise Network.
 ;;Based on Medsphere Systems Corporation's MSC FileMan 1051.
 ;;Licensed under the terms of the Apache License, Version 2.0.
 ;
START ;
 D INIT^DITMGM2B
 I $D(DITMGMQF) D EOJ Q
 D FILES
 D EOJ
 Q
 ;
FILES ; PROCESS ALL FILES/SUBFILES
 W:'$D(DITMGM2("NOTALK")) !!,"Merging entries",!
 F DITMGMFL=0:0 S DITMGMFL=$O(^UTILITY("DITMGMRG",$J,DITMGMFL)) Q:DITMGMFL=""  D FILE
 Q
 ;
FILE ; PROCESS ONE FILE/SUBFILE
 K DITMGMGM
 I $D(^DD(DITMGMFL,0,"UP")) S DITMGMMU=1 D EN^DITMU2(DITMGMFL,.DITMGMGM,1) S DITMGMG=$P(DITMGMGM,"DA(",1),DITMGMGM=$P(DITMGMGM,"DA,",1) I 1
 E  S DITMGMMU=0,DITMGMG=^DIC(DITMGMFL,0,"GL")
 F DITMGMFD=0:0 S DITMGMFD=$O(^UTILITY("DITMGMRG",$J,DITMGMFL,DITMGMFD)) Q:DITMGMFD'=+DITMGMFD  S DITMGMFS=DITMGMF,DITMGMTS=DITMGMT D FIELD^DITMGM2A S DITMGMF=DITMGMFS,DITMGMT=DITMGMTS
 Q
 ;
ZTM ; ENTRY POINT FOR TASKMAN
 S DITMGM2("NOTALK")=1
 D SEARCH^DITMGM2B
 D EOJ
 Q
 ;
EOJ ;
 K %K,D1,D2,DA,DIC,DI,DIPGM,DQ,I,V
 K DITMGDA,DITMGMDI,DITMGMDN,DITMGMEC,DITMGMFD,DITMGMFL,DITMGMFG,DITMGMFS,DITMGMG,DITMGMGG,DITMGMI,DITMGML,DITMGMGM,DITMGMN,DITMGMNO,DITMGMPC,DITMGMTS,DITMGMTY,DITMGMTZ,DITMGMMU,DITMGMPF,DITMGMV,DITMGMX,DITMGMXR
 I $D(ZTQUEUED) S ZTREQ="@"
 E  K:$D(ZTSK) ^%ZTSK(ZTSK),ZTSK ; old Kernel
 Q