What is the best way to identify the version of an incoming HL7 message?
I am expecting 2.3 & 2.3.1 messages coming in on a single channel and need to process the message versions differently (mainly PID segment).
Is the version being properly supplied in MSH-10? You could either create a separate message type in the VMD via Chameleon using the HL7 version as part of the Identification, or you could simply evaluate the contents of MSH-10 in a conditional:
if Msg.MSH:S() == "2.3" then -- do the version 2.3 stuff else -- do the version 2.3.1 stuff end
Jeff Drumm ◊ VP and COO ◊ HICG, LLC. ◊ http://www.hicgrp.com
This is assuming I have a vmd file that can parse both 2.3 & 2.3.1 messages. I am currently using the supplied vmd files for 2.3 & 2.3.1 and I would assume that if I tried using the 2.3.1 vmd to parse a 2.3 ADT message I would get an error as there is no patient identifier list field in 2.3.
I will try to make a vmd file to just map the MSH (same as the catch all in the demo.vmd) and see how I go from there.
You must be logged in to reply to this topic.
Please don't hesitate to take anonymous feedback survey or leave us a comment.