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

XBGXREFS.m

Go to the documentation of this file.
  1. XBGXREFS(FILE,FIELD,ROOT) ; IHS/ADC/GTH - GET XREFS FOR ONE FIELD IN ONE FILE ; [ 02/07/97 3:02 PM ]
  1. ;;3.0;IHS/VA UTILITIES;;FEB 07, 1997
  1. ;
  1. ; ATTENTION PROGRAMMERS: Do not use line one for entry.
  1. ; Use label XREF for entry.
  1. ;
  1. ; Given a file/subfile number, a field number, and a variable
  1. ; from which to assign subscripted values, this routine will
  1. ; return the xrefs for the specified field.
  1. ;
  1. ; The returned xrefs will be subscripted from the ROOT as
  1. ; follows:
  1. ;
  1. ; ROOT(FIELD,n) = file/subfile^xref (e.g. 9000010^AC)
  1. ; ROOT(FIELD,n,"K") = executable kill logic
  1. ; ROOT(FIELD,n,"S") = executable set logic
  1. ;
  1. ; Formal list:
  1. ;
  1. ; 1) FILE = file or subfile number (call by value)
  1. ; 2) FIELD = field number (call by value)
  1. ; 3) ROOT = array root (call by reference)
  1. ;
  1. G START
  1. ;
  1. XREF(FILE,FIELD,ROOT) ;PEP - Return x-ref info for a field.
  1. ;
  1. START ;
  1. NEW Y
  1. F Y=0:0 S Y=$O(^DD(FILE,FIELD,1,Y)) Q:Y'=+Y S ROOT(FIELD,Y)=^(Y,0),ROOT(FIELD,Y,"S")=^(1),ROOT(FIELD,Y,"K")=^(2)
  1. Q
  1. ;