Enter the OBR message. Ta da.
The OBR HL7 messages are used to send results, and the OBX segment of the message is what contains the actual results details. Often they might just be holding that information as text, but you can also cram whole files into the OBX segment. The problem with the OBX is that it is a bit of a jerk and likes to be all mysterious and poorly documented by systems that both produce and consume OBR messages.
The second field in the OBX determines how you are sending your data. You've got options here; these seem to be the least useless options of putting data into an OBX:
RP = Reference pointer
ST = String
FT = Formatted text
TX = Text data
ED = Encapsulated data
A message with two sets of results (two OBX segments) where one is formatted text and one is encapsulated data looks like this:
MSH|[snip]
PID|[snip]
PV1|[snip]
ORC|[snip]
OBR|[snip]
OBX|0001|FT|1006^MCH^L^28539-5^^LN||"this is formatted text"|pg|||||I
OBX|0002|ED|1003^Haemoglobin^L^718-7^^LN||ClientFile^application^pdf^Base64^CBSL0xlbmd0aCA2Ny9QcmV2IDk0MjIvUm9vdCAxMSAwIFIvU2l6ZSAzMi9[snip]
So, the OBX which is set to encapsulated data ('ED') has the base64 encoded binary contents of a PDF jamed into the OBX.5 field. That's kind of cool!
What these message actually look like on the recieving system I guess depends on how the application deals with them. In our results repository (Eclair), if you send a single ED OBX (containing for example a PDF) it will open and display the document in panel as shown to the left.
If you send multiple OBX segments then the ED ones will show with clickable icons.
Yuuussssss.
No comments:
Post a Comment