Split HL7 message onto multiple transactions

60 views
Skip to first unread message

ybor...@yahoo.com

unread,
Jun 23, 2009, 10:03:28 AM6/23/09
to InterSystems: Ensemble in Healthcare
We have Inbound hl7 transaction with multiple FT1 segments, which we
need to split into multiple HL7 messages, based on the number of FT1
segments. In our former Interface engine (eGate) this was a trivial
task, as it only required knowledge of few queue functions and a
loop. Can anyone share their experience with this problem?

Thanks

Yuriy

Graham, Ben

unread,
Jun 23, 2009, 1:15:43 PM6/23/09
to Ensemble-in...@googlegroups.com
Yuriy,
We solved the exact same problem using a routing rule.

First (rule 1), we use a transform to count the number of FT1 segments,
and populate an 'unused' MSH field (e.g. MSH:18). We also initialize a
second field (e.g. MSH 19) to 1.
You can also do any other needed transforms at this point.
The target for this rule is the business process that is using this
rule.

Rule 2, using the business process as the source, condition
MSH:18<=MSH:19, has two actions.
1. Create a new message, using the FT1 indicated by MSH:19, and
send to the business operation.
2. Create a copy of the original message, increment MSH:19, and
send back to the business process.

This will create a message for each FT1.

The export of the rule:

<?xml version="1.0" encoding="UTF-8"?>
<Export generator="Cache" version="22" zv="Cache for Windows (x86-32)
2008.2 (Build 526U)" ts="2009-06-23 10:14:14">
<Document name="BannerHealth.BprocRISChargeToBanner.rul"><routingRule
host="BannerHealth" name="BprocRISChargeToBanner"
context="BannerHealth.Context" doAll="false" source="" msgClass=""
docName="" docCategory="" docType="">
<description></description>
<rule source="ICCharge.Bproc.Router" msgClass="EnsLib.HL7.Message"
docName="" docCategory="ICCharge" docType="DFT_P03">
<action type="send" target="BannerHealth.Bproc.RISChargeToBanner"
transform="ICCharge.Transforms.UpdateFT1Count"></action>
</rule>
<rule source="BannerHealth.Bproc.RISChargeToBanner"
msgClass="EnsLib.HL7.Message" docName="" docCategory="ICCharge"
docType="DFT_P03">
<condition join="AND" operator="&lt;="
op1="HL7.{MSH:SequenceNumber}"
op2="HL7.{MSH:ContinuationPointer}"></condition>
<action type="send" target="BannerHealth.Bop.ChargeTCP"
transform="BannerHealth.Transforms.RisChargeToBannerCharge"></action>
<action type="send" target="BannerHealth.Bproc.RISChargeToBanner"
transform="ICCharge.Transforms.UpdateFT1Count"></action>
</rule>
</routingRule>
</Document></Export>

-Ben
This electronic transmission and any documents accompanying this electronic transmission may contain information that is confidential and/or legally privileged. The information is intended only for the use of the individual or entity named above. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution or the taking of any action in reliance on or regarding the contents of this electronically transmitted information is strictly prohibited. If you have received this e-mail in error, please notify the sender and delete this message immediately.

David Loveluck

unread,
Jun 24, 2009, 9:51:20 AM6/24/09
to Ensemble-in...@googlegroups.com
Yuriy

This is easy enough. You can't perform loops in message a simple message
router - they are designed for simple distribution and routing

In this case you can use BPL (or script if you prefer) to define a
process that loops until some condition is met.

In the attached example I have a DTL that among other things, copies ten
FT1 segments from source to target and then sends the message to a
business operation. The transform is called from the DTL until all FT1
segments have been processed. I keep track of where I got to in the BP
context.

The logic here applies to simple case where all repeating segments are
in a single group, but the same general idea applies to all arbitrarily
complex nested repeating groups.

I don't have an example of a DFT message at hand, so I haven't tested
this properly, but it should give you the general idea.

Dave

-----Original Message-----
From: Ensemble-in...@googlegroups.com
[mailto:Ensemble-in...@googlegroups.com] On Behalf Of
ybor...@yahoo.com
Sent: Tuesday, June 23, 2009 10:03 AM
To: InterSystems: Ensemble in Healthcare
Subject: [InterSystems-EnsHlth] Split HL7 message onto multiple
transactions


Junk.SplitProcess.xml

David Loveluck

unread,
Jun 24, 2009, 9:58:19 AM6/24/09
to Ensemble-in...@googlegroups.com
I meant to say

"The transform is called from the BPL until all FT1 segments have been
processed."

Dave

David Loveluck
617 225 3122

David Loveluck

unread,
Jun 24, 2009, 3:33:42 PM6/24/09
to Ensemble-in...@googlegroups.com

I found a DFT_P03 message to test and then modified my example. It is still just a sample.

 

Dave

 

-----Original Message-----
From: David Loveluck
Sent: Wednesday, June 24, 2009 9:58 AM
To: Ensemble-in...@googlegroups.com
Subject: RE: [InterSystems-EnsHlth] Re: Split HL7 message onto multiple transactions

 

I meant to say

 

"The transform is called from the BPL until all FT1 segments have been processed."

 

Dave

 

David Loveluck

617 225 3122

 

-----Original Message-----

From: Ensemble-in...@googlegroups.com [mailto:Ensemble-in...@googlegroups.com] On Behalf Of David Loveluck

Sent: Wednesday, June 24, 2009 9:51 AM

To: Ensemble-in...@googlegroups.com

Subject: [InterSystems-EnsHlth] Re: Split HL7 message onto multiple transactions

Junk.SplitProcess.xml
Reply all
Reply to author
Forward
0 new messages