do the child segments have to be in a specific order? or is there any other criteria by which the code knows what is / is not a child?
here's the gist of what i'm doing:
obr = msg[:OBR].select{|seg| ... some critieria to get the right OBR}.first
obx = obr.children.select{ |seg| ... more criteria to get the right obx}
but when i run this, obr.children comes back as empty.
my file has OBR / OBX data. here's a sample of the data i'm using:
OBR|14|...|
OBX|1|...|
OBX|2|...|
OBX|3|...|
OBR|15|...|
OBX|1|...|
my code is looking for OBR 14, and finding it. i'm getting the correct OBR segment back... but no children for it.
any ideas?
-derick