Announcement

Collapse
No announcement yet.

X12 to XML output

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • X12 to XML output

    Hello everyone. I am using Mirth for HL7 processing, however I also have X12 EDI documents that I need converted to XML. I currently use the program Bots(http://bots.sf.net/) for conversion, but I'd much rather use Mirth.

    It's been really easy to configure Mirth to do a simple conversion, but it does not respect relationships between segments. For example, if I have a purchase order (PO1) segment, there will be an associated product/item desc.(PID) segment as well.

    Currently, my output from Mirth will look something like
    HTML Code:
    <PO1>
    	<PO1.01>
    		<PO1.01.1>1</PO1.01.1>
    	</PO1.01>
    	<PO1.02>
    		<PO1.02.1>000000005</PO1.02.1>
    	</PO1.02>
    	<!-- etc... -->
    </PO1>
    <PID>
    	<PID.01>
    		<PID.01.1>F</PID.01.1>
    	</PID.01>
    	<PID.02 />
    	<!-- etc... -->
    </PID>
    Where both segments are represented, but the PID should be a child of the PO1 segment, rather than a sibling.

    If there is some way to achieve this with Mirth please let me know. If you need any clarification, I'll be more than happy to explain it further.

    Thanks

  • #2
    I have done a few x12 to xml channels. The internal x12 xml structure is probably not what you need or want. We mainly convert it to xml so that we can more easily do transformation with the data. It would be better to define your own xml structure and write a javascript transformer to convert the data.
    Daniel Svanstedt
    Software Engineer
    Mirth Corporation

    Want professional services, support, and enterprise or virtual appliances? It's all available from the Mirth Corporation:
    Mirth Support | Mirth Training | Mirth Appliances | Online Training | Developer Q&A

    Don't forget, Mirth Support gives you access to all of our online training videos, and silver support gives you access to developer Q&As!

    Comment


    • #3
      Thanks for the quick response!
      I have a good grasp of XML and a great handle on Javascript, so I just need a starting point. Is there some tutorial or other resource available that would point me in the right direction?

      Thanks again.

      Comment


      • #4
        You should be good to go with javascript and xml. Take a look at the Mirth wiki and at the following: http://www.faqts.com/knowledge_base/...phtml/fid/1762

        Also worth considering Mirth Corp training and/or support.
        Daniel Svanstedt
        Software Engineer
        Mirth Corporation

        Want professional services, support, and enterprise or virtual appliances? It's all available from the Mirth Corporation:
        Mirth Support | Mirth Training | Mirth Appliances | Online Training | Developer Q&A

        Don't forget, Mirth Support gives you access to all of our online training videos, and silver support gives you access to developer Q&As!

        Comment

        Working...
        X