web stats
HL7 v3 (XML) importer in python - Mirth Community

Go Back   Mirth Community > Open Source HIT > General Discussion

Thread Tools Display Modes
Old 08-06-2010, 02:54 PM
lkcl lkcl is offline
What's HL7?
Join Date: Aug 2010
Posts: 2
lkcl is on a distinguished road
Default HL7 v3 (XML) importer in python

this is to let people know that there exists the beginnings of an HL7v3 python project, thanks to john paulett's fantastic work creating an HL7v2 parser. read here for the announcement:
and here for the code:

the code makes use of mirthcorp.com published HL7 specifications (in XML file format) to create revision-dependent segment and field parsers. the implications are that even one person can keep the hl7 python module relevant and up-to-date with the latest HL7 specifications, as long as mirthcorp continue to publish the XML files.

added on top of john's excellent work is a python-style interface of properties. so, it is possible to do this:
p = hl7.PID
print "patient", p.patient_id_internal_id, \

the names of the properties are auto-generated directly from mirthcorp's XML specifications. ORCs are matched with ORBs via the filler order number, so it is possible to do "hl7.ORC[0].ORB"; ORCs and ORBs are both given a property of ORX, so it is possible to do "hl7.ORC[0].ORB.ORX[3]"; NTEs are also supported if they exist.

hope this is useful to someone. anyone wishing to either contribute or sponsor the work for use in any project, please do contact me.

Reply With Quote

hl7 python

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:35 PM.

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