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

PRC5192P.m

Go to the documentation of this file.
  1. PRC5192P ;BP/TJH - IFCAP Post-Init for PRC*5.1*92 ; 28 Oct 2005 3:16 PM
  1. ;;5.1;IFCAP;**92**;Oct 20, 2000
  1. QUIT
  1. ;
  1. START ; remove invalid entries from the "C" xref of file #442
  1. D BMES^XPDUTL("Removing invalid entries from the C xref of file #442...")
  1. N PRCDA,PRCDB,PRCREC,PRCPO
  1. S PRCDA=0,U="^"
  1. F S PRCDA=$O(^PRC(442,"C",PRCDA)) Q:PRCDA="" D
  1. . S PRCDB=0
  1. . F S PRCDB=$O(^PRC(442,"C",PRCDA,PRCDB)) Q:PRCDB="" D
  1. .. S PRCREC=$G(^PRC(442,PRCDB,0)) ; get associated record, zero node
  1. .. S PRCPO=$P($P(PRCREC,U,1),"-",2) ; extract purchase order w/o STATION NUMBER
  1. .. I PRCPO'=PRCDA K ^PRC(442,"C",PRCDA,PRCDB) ; if PO# doesn't match subscript, remove the xref entry.
  1. D BMES^XPDUTL("Cleanup of C xref complete.")
  1. Q