Than you, Jerry, for your reply. Your approach is clever and should work.
I’ve a question: I set up the [lsearch -regexp -all $segments ^OBR] and assigned it to obr_locations. However, when I do a “foreach obr_location $obr_locations” what I’m getting is the location of the OBR segment within the message, not the segment itself. How do I tie the location back to the segment?
~marv