web stats
HL7v3 into HL7v2 - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 10-25-2017, 06:24 AM
Vay Vay is offline
What's HL7?
 
Join Date: Oct 2017
Posts: 2
Vay is on a distinguished road
Default HL7v3 into HL7v2

Hello,
i would like to transform a HL7v3 XML message into a HL7v2 message.

My Channel looks like this:

Summary -> Set Data Types
Source Connector:
-Inbound HL7 v3.x
-Outbound HL7 v2.x

Destination 1
-Inbound HL7 v2.x
-Outbound HL7 v2.x

Source -> nothing special
Destinations -> Template: ${message.encodedData}

The converted message looks like this:
POLB_IN224200UV01|templateId|id|creationTime|inter actionId|processingCode|processingModeCode|acceptA ckCode|receiver|device|id|sender|device|id|control ActProcess|code|languageCode|subject|observationBa ttery|id|code|statusCode|recordTarget|patient|id|p atientPerson|name|given|ANDRES FELIPEfamily|FERNANDEZ CORTESadministrativeGenderCode|birthTime|author|ti me|assignedEntity|assignedDevice|id|manufacturerMo delName|

Do i need to build a Templatefile?
If i need to build it, at which step (source or destination) i need to insert it?

There is a tutorial that shows the other way around (hl7 to xml) http://www.mirthcorp.com/community/w...pageId=5210134
Sadly, this steps don't seem to work in my direction.

I appreciate any help and suggestions.
Reply With Quote
  #2  
Old 10-25-2017, 09:13 AM
Shamil Shamil is offline
OBX.3 Kenobi
 
Join Date: May 2013
Posts: 151
Shamil is on a distinguished road
Default

The tutorial you are pointing explains translation of the inbound HL7v2 message using default encoding (i.e., delimiter based formatting) into outbound HL7v2 XML- formatted message. The latter is defined by HL7 Version 2: XML Encoding Syntax specification, but Mirth encoding does not fully follow it unless you are using a strict parser mode. It’s an error where it says that the resulted message is HL7v3.

The HL7v3 is completely different, RIM based, beast. There is no built-in automated solution to translate from v2 to v3 (and it should not be so since your v3 message is likely a constrained version with possible local extensions).

Last edited by Shamil; 10-25-2017 at 12:00 PM.
Reply With Quote
  #3  
Old 10-25-2017, 11:37 PM
Vay Vay is offline
What's HL7?
 
Join Date: Oct 2017
Posts: 2
Vay is on a distinguished road
Default

I just found out what to do.

I received a XML template which i pasted into the "Message Templates" Source Transformer tab. I also got a v2 template for the "Outbound Message" field.

My problem was that i didn't knew that i can connect the inbound Message Tree fields with the outbound tree fields.

It works fine now
Reply With Quote
  #4  
Old 10-26-2017, 04:52 AM
kirbykn2's Avatar
kirbykn2 kirbykn2 is offline
Mirth Guru
 
Join Date: Sep 2014
Location: Michigan
Posts: 567
kirbykn2 is on a distinguished road
Default

Can you post your channel?
__________________
Kirby

Mirth Certified|Epic Bridges Certified|Cloverleaf Level 2 Certified

Appliance Version 3.11.2
Mirth Connect Version 3.6.1
Java Version 1.6.0_45-b06
Java (64 bit) Version 1.6.0_45-b06
Java 7 (64 bit) Version 1.7.0_151-b15
Java 8 (64 bit) Version 1.8.0_121-b13
PostgreSQL Version 9.6.3
Reply With Quote
Reply

Tags
hl7v3, transformer template

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 02:23 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Mirth Corporation