What is HL7
HL7 (Health Level Seven) Is one of several American National Standards Institute (ANSI) -accredited Standards Developing Organizations (SDOs) operating in the health care arena for exchanging clinical and administrative data between medical applications.
"7" refers to the seventh layer in the OSI model. This standard defines the format and the content of the messages that medical applications must use when exchanging data with each other and does not explains the the technical details on how the data should be exchanged.
Structure of HL7 message.

HL7 message is consists of segments and they are represented by 3 letter word. each segment consists of field which consists of components and then the sub-components.
The default message delimiters are
^ component separator
~ : repetition separator
\ : Escape character
& : Sub component separator
What is Trigger Event:
Each HL7 message contains a message type and trigger event. Each message message type is triggered by HL7 events. The message type and trigger event information is found in the first segment i.e. MSH.
Example:
ADT A01: Patient Admit
HL7 (Health Level Seven) Is one of several American National Standards Institute (ANSI) -accredited Standards Developing Organizations (SDOs) operating in the health care arena for exchanging clinical and administrative data between medical applications.
"7" refers to the seventh layer in the OSI model. This standard defines the format and the content of the messages that medical applications must use when exchanging data with each other and does not explains the the technical details on how the data should be exchanged.
Structure of HL7 message.

HL7 message is consists of segments and they are represented by 3 letter word. each segment consists of field which consists of components and then the sub-components.
The default message delimiters are
^ component separator
~ : repetition separator
\ : Escape character
& : Sub component separator
What is Trigger Event:
Each HL7 message contains a message type and trigger event. Each message message type is triggered by HL7 events. The message type and trigger event information is found in the first segment i.e. MSH.
Example:
ADT A01: Patient Admit
MSH|^~\&|System|HIS|HL7Genie|Hosp|20050804162010||ADT^A01|Message Control ID|P|2.3.1|||AL|AL
EVN|A01|199901061000|199901101400|01||199901061000
PID|1||191919^ABC~110-86-9016|3253763|Name^NAME^A||19560129|M|||007 BANAGALORE^^KARNATAKA^560001
PV1||O|||||018^DrPeaceAttending|0018^DrPeaceReferring|018^DrPeaceConsulting|CAR Hostpital service
PV2||||||||199901101400|||||||||||||||||||||||||199901101400
EVN|A01|199901061000|199901101400|01||199901061000
PID|1||191919^ABC~110-86-9016|3253763|Name^NAME^A||19560129|M|||007 BANAGALORE^^KARNATAKA^560001
PV1||O|||||018^DrPeaceAttending|0018^DrPeaceReferring|018^DrPeaceConsulting|CAR Hostpital service
PV2||||||||199901101400|||||||||||||||||||||||||199901101400
MSH: Details about the message such as Message Type, Sending, receiving application, date, Acknowledgment required or not
EVN: Used to communicate necessary trigger event information to receiving applications. Tells about the person triggering the event patient/doctor
PID: Contains permanent patient information identifying and demographic information that is not likely to change frequently.
PV1: Details of the patient’s visit to hospital,such as Bed, Inpatient/out patient/emergency,visit id, doctor with whom patient is consulting.
PV2: Is a continuation of visit-specific information contained on the PV1 segment.
EVN: Used to communicate necessary trigger event information to receiving applications. Tells about the person triggering the event patient/doctor
PID: Contains permanent patient information identifying and demographic information that is not likely to change frequently.
PV1: Details of the patient’s visit to hospital,such as Bed, Inpatient/out patient/emergency,visit id, doctor with whom patient is consulting.
PV2: Is a continuation of visit-specific information contained on the PV1 segment.