The Mapping Table consists of one or more lines of ascii text, with each line representing a field in an HL7 record. Each line consists of up to 7 pieces of information, with each piece separated by a comma.
NOTES ON USE OF LOGICAL EXPRESSIONS:
Specify a "logical expression" on a mapping field if the value is only to be used based on a specific condition.
Any field that exists in the Reports table can be used in a logical expression without using bracketed field notation. If fields from other tables are required, then bracketed field notation must be used.
If bracketed fields are required, surround them with double-quotes. Example: "[r.doctor.d.elecsig)"="TRUE".
If testing a Boolean field, compare to "TRUE" or "FALSE" (double quotes required).
SYNTAX: Database field,HL7 segment,piece#,sub-piece#,format code,string expression,logical expression
EXAMPLES:
The following is an example of a mapping table for creating an HL7 outbound result file.
The mapping table is defined in the "Interface Map" page of the Device file maintenance
^~\&,MSH,1
CHARTNET,MSH,2
TEST,MSH,3
TEST,MSH,4
TEST,MSH,5
X.SYSTEMDATE,MSH,6
ORU R01,MSH,8
R.REPORT_ID,MSH,9
P,MSH,10
2.2,MSH,11
R.MRUN,PID,3
R.PTNAME,PID,5,1,NAME
R.ACCTNO.M.ADDRESS,PID,11
R.ACCTNO,PID,18
R.ORDERNO,OBR,3,1
X.DICTDATE,OBR,22
R.STATUS,OBR,25
FT,OBX,2
#USESEQ
The below logical expression will return the attending doctor's code in OBR,33,2 if the attending is not the dictating doctor.
R.ATTDR,OBR,33,2,,,ATTDR<>DOCTOR
The below logical expression will send an F (final) if a custom user field is not an addendum, and will send a C (correction) if the custom user field is an addendum:
F,OBR,25,1,,,12A_USER1<>"ADDENDUM"
C,OBR,25,1,,,12A_USER1="ADDENDUM"