Reputation: 55
I'm trying to parse an HL7 message file which is of version 2.3.1. OBX segment is coming as null when the message is parsed.
If I don't have OBR segment in HL7 message, Terser is failing to fetch the OBX segment values (it's returning null values), so is OBR segment mandatory to view OBX attachments in an HL7 message?
Upvotes: 3
Views: 2859
Reputation: 11
While the OBR segment is stated as mandatory in the HL7 standards for most messages the parser software you are using may allow you to set it as optional.
Deciding to do this though should be considered only if there is a good reason why the sending system cannot or will not include the OBR segment in the message.
Upvotes: 0
Reputation: 16389
The OBX
segment mainly carry clinical report data. It is mainly used in ORU
message and rarely with ORM
, ADT
and other. This segment is optional and can be repeated in message.
The OBR
segment mainly carry placer and filler order numbers (used as identifiers), exam information etc. This segment is mandatory.
ORU (Observation Result) messages should contain the OBR segment followed by the OBX segment for each observation.
About its usage in ORM
message:
Usage in the ORM Message
In an ORM message, the OBR segment is part of an optional group that provides details about the order. When the order placer creates the ORM message, they will include the Placer Order Number in the OBR-2 and/or ORC-2 fields. These two fields should contain the same information, and at least one of the two must contain the placer order number. The message may contain multiple orders for which the rules still apply.
About its usage in ORU
message:
Usage in the ORU Message
In an ORU message, the OBR segment is used as a report header and contains important information about the order being fulfilled (i.e. order number, request date/time, observation date/time, ordering provider, etc.). It is part of a group that can be used more than once for each observation result that is reported in the message.When the filler creates the ORU message, they will include the Filler Order Number (such as an accession number) in the OBR-3 and/or ORC-3 fields. If the filler order number is not present in the ORC-3, it must be present in the OBR-3 because the ORC segment is optional in the ORU message.
Considering this, OBR
is mandatory segment in both the ORU
and ORM
(optional group) messages. This is irrespective of dependency of OBX
segment on OBR
segment.
To answer your comment, I never used REF
message. But, first google search gave me this. It look that OBR
is mandatory in those messages.
Upvotes: 1