source: WorldVistAEHR/trunk/r/TEXT_INTEGRATION_UTILITIES-GMRP-TIU/TIUPS148.m@ 1361

Last change on this file since 1361 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 1.5 KB
RevLine 
[613]1TIUPS148 ; SLC/CAM-Creates PATIENT ETHNICITY TIU Object;10/31/02
2 ;;1.0;TEXT INTEGRATION UTILITIES;**148**;JUN 20,1997
3 ;
4 ; This patch was created to define the PATIENT ETHNICITY TIU data object
5 ; in the TIU DOCUMENT DEFINITION file (8925.1).
6 ; Once the PATIENT ETHNICITY object is created and functioning this
7 ; routine can be deleted.
8 ; If a TIU object named PATIENT ETHNICITY already exists on the system
9 ; in which this routine is being installed the Object Method field (9)
10 ; of the TIU DOCUMENT DEFINITION file (8925.1) will be overridden with
11 ; the National Object Method for PATIENT ETHNICITY.
12 ;
13 N TIUDA,TIUOBNM
14 S TIUDA=0,TIUOBNM="PATIENT ETHNICITY"
15 S TIUDA=$$FIND1^DIC(8925.1,"","AMX",TIUOBNM,"D^C^B","I $P(^TIU(8925.1,+Y,0),U,4)=""O""","ERR")
16 I TIUDA'=0 D OBCHG Q
17 I TIUDA=0 D CREATE Q
18 ;
19CREATE ; Creates the PATIENT ETHNICITY TIU Object
20 ;
21 N FDA,FDAIEN,MSG
22 S FDA(8925.1,"+1,",.01)=TIUOBNM
23 S FDA(8925.1,"+1,",.03)=TIUOBNM
24 S FDA(8925.1,"+1,",.04)="O"
25 S FDA(8925.1,"+1,",.05)=DUZ
26 S FDA(8925.1,"+1,",.07)="11"
27 S FDA(8925.1,"+1,",9)="S X=$$ETHNIC^TIULO(DFN)"
28 S FDA(8925.1,"+1,",99)=$H
29 ;
30 D UPDATE^DIE("","FDA","FDAIEN","MSG")
31 ;
32 I $D(MSG) D Q
33 . W !!,"TIU Object failed. The following error message was returned:",!!
34 . S MSG="" F S MSG=$O(MSG("DIERR",1,"TEXT",MSG)) Q:MSG="" W MSG("DIERR",1,"TEXT",MSG),!
35 ;
36 W !!,"TIU Object created successfully"
37 ;
38 Q
39OBCHG ; Changes existing PATIENT ETHNICITY Object
40 N DA,DIE,DR,X,TIUVAR
41 ; Change Object Method
42 S TIUVAR="S X=$$ETHNIC^TIULO(DFN)",DIE="^TIU(8925.1,",DR="9///^S X=TIUVAR",DA=TIUDA
43 D ^DIE
44 ;
45 Q
Note: See TracBrowser for help on using the repository browser.