Mirth Community

Mirth Community (http://www.mirthcorp.com/community/forums/index.php)
-   Support (http://www.mirthcorp.com/community/forums/forumdisplay.php?f=6)
-   -   Deleting fields (http://www.mirthcorp.com/community/forums/showthread.php?t=222219)

rutledj 01-13-2020 11:03 AM

Deleting fields
 
Is there a way to delete all of the fields in a given segment that occur after a certain field?

I need to delete all fields in the EVN segment, after the 6th field, so that it only contains 6 fields. I'm not seeing an easy way to do this.

cory_cole 01-13-2020 11:29 AM

msg['OBX'] = msg['OBX.1'] +msg['OBX.2'] +msg['OBX.3'] +msg['OBX.4'] +msg['OBX.5']

will give you segments 1 - 5;

agermano 01-13-2020 03:26 PM

Quote:

Originally Posted by cory_cole (Post 271392)
msg['OBX'] = msg['OBX.1'] +msg['OBX.2'] +msg['OBX.3'] +msg['OBX.4'] +msg['OBX.5']

will give you segments 1 - 5;

No, it won't, but this will (assuming there is only 1 OBX segment)
Code:

msg['OBX'] = <OBX>{msg['OBX.1'] +msg['OBX.2'] +msg['OBX.3'] +msg['OBX.4'] +msg['OBX.5']}</OBX>


All times are GMT -8. The time now is 12:22 PM.

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