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

RA57PST.m

Go to the documentation of this file.
  1. RA57PST ;HIOFO/SWM-Post install ;12/20/04 12:55am
  1. ;;5.0;Radiology/Nuclear Medicine;**57**;Mar 16, 1998
  1. ; This is the post-install routine for patch RA*5.0*57
  1. ; It will loop thru file 79.2 and insert appropriate Dept Code
  1. ;
  1. ; This routine may be deleted after RA*5.0*57 is installed.
  1. ;
  1. ; Variable initialization.
  1. N RA1,RA2,RAFDA,RATXT,RAVAL,RAX
  1. S RATXT(1)=""
  1. S RATXT(2)="** File 79.2 IMAGING TYPE has been updated with Dept. Code for the PFSS project. **"
  1. S RA1=0
  1. ; Traverse the IMAGING TYPE FILE
  1. F S RA1=$O(^RA(79.2,RA1)) Q:'RA1 I $D(^(RA1,0)) D
  1. . ; Gather the data from the zero node and extract the first 3 characters of the .01 (NAME) field.
  1. . S RA2=^RA(79.2,RA1,0),RAX=$E(RA2,1,3)
  1. . ; Inspect the extracted characters and assign a code number associated with that string.
  1. . S RAVAL=$S(RAX="GEN":"105",RAX="NUC":"109",RAX="ULT":"115",RAX="MAG":"151",RAX="CT ":"150",RAX="ANG":"152",RAX="CAR":"109",RAX="VAS":"421",RAX="MAM":"703",1:"")
  1. . S RAFDA(79.2,RA1_",",90)=RAVAL ; Dept Code is in field #90.
  1. . D FILE^DIE("K","RAFDA") ; Use filemans function to populate the field.
  1. . ; If there is an error returned set up special error text.
  1. . I $D(RAMSG) S RATXT(2)="** Error in updating file 79.2 IMAGING TYPE with Dept. Code for the PFSS project. **"
  1. . ; End of task loop
  1. . Q
  1. ; Display any message returned from the filing activity.
  1. D MES^XPDUTL(.RATXT)
  1. Q