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

AMERPRE1.m

Go to the documentation of this file.
AMERPRE1 ; IHS/OIT/SCR - PRE-INIT ROUTINE FOR ERS V3.0 patch 1 ; 
 ;;3.0;ER VISIT SYSTEM;**1**;FEB 23, 2009
EDITMETA ;
 ; REMOVE UNWANTED ENTRIES FROM ER METADATA ^AMER(2.2
 N AMERNUM,AMERIEN,AMERTAGS,AMERTAG,DA,DIK
 S AMERNUM=1,AMERIEN=0
 S AMERTAGS="CURRENT COMMUNITY^BENEFICIARY CLASS^DIAGNOSTIC CATEGORY^EMERGENCY TRANSPORT^FINAL CONDITION^DOA^TRIBE^ELIGIBILITY"
 F  S AMERTAG=$P(AMERTAGS,"^",AMERNUM) Q:AMERTAG=""  D
 .S AMERIEN=$O(^AMER(2.2,"B",AMERTAG,AMERIEN))
 .I AMERIEN'="" D
 ..S DIK="^AMER(2.2,"
 ..Q:AMERIEN<0
 ..S DA=AMERIEN
 ..D ^DIK
 ..D IX^DIK
 ..Q
 .S AMERNUM=AMERNUM+1,AMERIEN=0
 .Q
 Q