web stats
Mirth SubComponent - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 11-21-2019, 06:10 AM
Mirthvu14 Mirthvu14 is offline
OBX.1 Kenobi
 
Join Date: Jan 2019
Posts: 34
Mirthvu14 is on a distinguished road
Default Mirth SubComponent

Hello,
I have a message that arrive to my channel, that has some subcomponent.
In the section 'Set Data Types' so I use the 'Parse Subcomponenents' and it works fine.

But in a OBX.5.1 they send me a description 'text1 & text2' that is not a subcomponent, but it is just the text of the description.
So Mirth see this:
<OBX.5.1>
<OBX.5.1.1>text1 </OBX.5.1.1>
<OBX.5.1.2> text2</OBX.5.1.2>
</OBX.5.1>

They say that in the text of the description they often use the '&' so I have to find an automatic way to find this text, that aren't subcomponent.
I need to use the 'Parse Subcomponenents' in the 'Set Data Types' because in the message there are some other sub components.
How can I do?
Reply With Quote
  #2  
Old 11-21-2019, 06:51 AM
cory_cole cory_cole is offline
Mirth Guru
 
Join Date: Mar 2012
Posts: 1,344
cory_cole is on a distinguished road
Default

msg['OBX']['OBX.5']['OBX.5.1'].toString() and
msg['OBX']['OBX.5']['OBX.5.2'].toString()
Reply With Quote
  #3  
Old 11-22-2019, 05:34 AM
agermano agermano is offline
Mirth Guru
 
Join Date: Apr 2017
Location: Indiana, USA
Posts: 1,059
agermano is on a distinguished road
Default

I wrote a tool for that https://github.com/nextgenhealthcare...0Subcomponents

You can join any fields that you suspect may have an & in the data.

Alternatively, you can turn off "parse subcomponents" and split the field yourself to access the different parts for the fields that you know do have subcomponents.
Reply With Quote
Reply

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 03:47 AM.


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