infor.com
concierge
infor u
developer portal
documentation central
customer center
Posts
Categories
Groups
ERPs
CSD
FSM/HRT
LN
M3
Syteline/ CSI
Hubs
Developer
Healthcare
Hospitality
Public Sector
Onboarding
Release Center
CloudSuites
Aerospace & Defense (LN)
Automotive (LN)
Chemicals (M3)
Corporate (FSM/HRT)
Distribution (Sx.e/CSD)
Distribution Enterprise (M3)
Engineering & Construction (LN)
Fashion (M3)
Food & Beverage (M3)
Healthcare (FSM/HRT)
Industrial (Syteline/CSI)
Industrial Enterprise (LN)
Manufacturing (M3)
Public Sector (FSM/HRT)
Solutions
Supply Chain Management (SCM)
Human Capital Management (HCM)
Events
Groups
User Groups
Your Groups
About
Email Community Support
Infor News
Migrated Forums
Home
Clovertech
Clovertech Archive
Cloverleaf
how to remove unwanted pipes in the middle of a segment?
Jason
so in one of the SIU messages we process, one of the sub-fields is a comment field and the upstream system allows pipes (|) to come through. Of course when they do it messes up the entire segment because it pushes down every other field thinking the pipes in the comment field are separators. Basically it's like SQL-injection but with HL7 messages.
is there anything I can do about this?
Find more posts tagged with
Clovertech
Comments
Paul Bishop
There's really not much you can do in a case like this since you don't know how many pipes they put in the field. You can try pushing back at the vendor who is creating the message and see if they can follow the HL7 standards for escaping any delimiter characters, which for the field separator would be "\E\" (assuming "|^~\&" in the MSH segment).
I did get to thinking though, is this in the NTE segment? If so, the number of fields is limited so you might be able to figure out which pipes are part of the comment.
jnelson
What version of HL7 is it using? HL7 v2.3 only has 3 fields defined in the NTE segment so you could, with a small risk, assume that any pipe character after the first 3 is part of the comment and use 'string map' within a tclproc to convert them to the appropriate escape sequence. HL7 v2.5 has a fourth field, but that could be accounted for as well if you know the valid comment types.
Charlie Bursell
If you know which subfield it is, it could be done in a pre-proc.
However, it is much better to quote the HL7 spec to your vendor :-)