· May 18

Common transformation for different HL7v2 ADT message types

In over a decade of using Ensemble/HealthShare, we have been able to use a single message type (doc type) for all HL7 ADT event types. We now have an application for which the HL7 segment sequence is different for A03s than it is for other ADT event types. The content of the segments is the same across event types; only the segment sequence differs. The data transformation has to do some custom logic, so we can't just use the "copy" variety of the transformation Create property.

Because a different message schema has to be used for A03s, the only way I can think of accomplishing this is to have one transformation for the A03 messages and another transformation for the other ADT event types. Because the transformation rules will be identical in both, we'd essentially have duplicate transformations. And that means remembering to maintain two transformations for future changes.

Does anyone have a simpler/better idea for handling more than one schema for which transformation rules don't differ across those schemas?

Product version: HealthShare 2018.1
$ZV: Cache for UNIX (IBM AIX for System Power System-64) 2018.1.7 (Build 721U) Fri Mar 18 2022 22:09:15 EDT [HealthShare Modules:Core:15.032.9070 + Linkage Engine:15.032.9070]
Discussion (3)3
Log in or sign up to continue

You could also try adding a code section to you DTL, similar to this.

//this part collates the info to set the doctype
 set version=target.GetValueAt("MSH:VersionID.versionID")
 set type=target.GetValueAt("MSH:MessageType.messagetype")
 set trigger=target.GetValueAt("MSH:MessageType.triggerevent")
 //set trigger="A05"
 if ((trigger = "A08")!(trigger = "A11")!(trigger = "A27")!(trigger = "A03")!(trigger = "A12")!(trigger = "A13")){SET trigger = "A01"}
 //this sets the doctype
 set target.DocType=version_":"_type_"_"_trigger
 //set target.DocType="2.4:ADT_A05"