Recently I had a requirement to generate an HL7 ORM to send to Oracle.
To fulfill the requirements, an HL7 message must be generated inline inside an orchestration.
The ExecuteReceivePipeline method must be used in orchestration, to execute the BTAHL72XSendPipeline pipeline with the HL7 multipart message to finally generate the message in HL7 format.
All HL7 must be multipart messages consisting of three segments:
- Body segment – The HL7 message (marked as message body part)
- MSH segment – The HL7 header
- Z Segment – HL7 custom segment
To generate the ORM HL7 message, the BTAHL72XSendPipeline requires that the “message type” property be promoted, otherwise the error “Body schema is missing” will be thrown.
This property cannot be directly set, because is a reserved property used by BizTalk, the only way is to copy from other message.
If your orchestration receives the same HL7 message type, it’s easy to fix this issue, just set the multipart properties from the inbound message using the “(*)” syntax. In this way, the “message type” property will be copied.
HL7MultipartMessage(*)=InputMsgForHl7BodyPart(*);
There are several posts with this fix like https://blogs.msdn.microsoft.com/biztalknotes/2013/03/06/biztalk-hl7-error-failure-executing-btahl72xsendpipeline-error-details-body-schema-is-missing/ and https://social.technet.microsoft.com/wiki/contents/articles/16181.how-to-execute-btahl72xsendpipeline-in-an-orchestration.aspx
If you do not have an incoming HL7 message, the solution is a little bit tricky.
- Create an BizTalk ORM message (you can use other HL7 message type or versions depending of the business requirements);
- Force the “message type” promotion executing the XmlReceive pipeline (inline in orchestration);
- Set the message created in1) to the multipart BodySegments segment;
- Copy the ORM properties to the multipart message ( HL7MultipartMessage(*)=ORMMessage(*) )
Hope this helps!
It’s a technology that I like to be able to use for myself. It’s definitely a cut above the rest and I can not wait until my provider has it. Your insight was what I needed to thank you.
Office 365 Support