I think I figured this out.


The IN1 segment doesn’t repeat but the ADT_A01_INSURANCE group it’s
under does repeat. So I would have to get the INSURANCE group at index
1 and then the IN1 and index 0 of that group.



Is there any way to get this data from the terser knowing only the
segment name and index?



*From:* Jonathan Bartels [mailto:[email protected]]
*Sent:* Thursday, October 14, 2010 3:31 PM
*To:* [email protected]
*Subject:* Is this the correct path to give the Terser for a repeating
segment?



Using code posted in another thread I am getting the number of repeating
segments in a message then iterating over those segments to get data using a
for loop and a terser.



The message is:

MSH|^~\&|ADM|CLF654321||CLF123456|200612131130||ADT^A08|4323424|P|2.5|||AL|NE

PID…

GT1…

IN1|1||somedata

IN1|2||somedata



Using a terser string, “/.IN1(1)-3-1”, I get this error:

ca.uhn.hl7v2.HL7Exception: Can't create repetition #1 of Structure IN1 -
this Structure is non-repeating



Do I need to also specify a field repetition?
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Hl7api-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/hl7api-devel

Reply via email to