Luận văn Nghiên cứu chuẩn HL7 dùng trao đổi dữ liệu điện tử trong y khoa và xây dựng chương trình đọc bản tin HL7

MỤC LỤC

LỜI CẢM ƠN. ii

TÓM TẮT LUẬN VĂN. iii

MỤC LỤC. iv

CHƯƠNG 1: GIỚI THIỆUU

1.1. Mở đầu . 1

1.2. Mục tiêu và nhiệm vụ của luận văn . 2

CHƯƠNG 2: TỔNG QUAN

2.1. LỊCH SỬ CHUẨN THÔNG TIN Y TẾ HL7 . 3

2.2. NGUYÊN TẮC MÃ HÓA TRONG HL7. 6

2.2.1. Nguyên tắc . 6

2.2.2. Ví dụ về mã hóa và giải mã một bản tin HL7. 6

2.3. CÁC KHÁI NIỆM CƠ SỞ TRONG HL7 . 7

2.3.1. Sự kiện kích khởi (trigger event) . 7

2.3.2. Môi trường truyền thông. 11

2.3.3. Bản tin. 13

2.3.4. Đoạn. 14

2.3.5. Trường. 14

2.3.6. Ký hiệu phân định bản tin (message delimiter) . 18

2.3.7. Loại dữ liệu . 20

2.3.8. Sử dụng các trình tự thoát ra trong trường văn bản . 27

2.3.9. Các quy luật kiến trúc dữ liệu . 30

2.3.10. Cấu tạo một bản tin quản trị bệnh nhân . 32

2.4. CẤU TRÚC BẢN TIN NHẬP VIỆN . 33

Bản tin đăng ký bệnh nhân – ADT/ACK (sự kiện A04). 33

2.4.1. Đoạn mào đầu bản tin (MSH – Message Header Segment). 34

2.4.2. Đoạn loại sự kiện (Event type segment – EVN) . 40

2.4.3. Đoạn xác nhận bệnh nhân (Patient Identification segment – PID) . 42

2.4.4. Đoạn thân nhân bệnh nhân (Next of kin / associated parties segment –

NK1). 51

2.4.5. Đoạn thông tin nhập viện (Patient Visit segment – PV1) . 58

2.4.6. Đoạn thông tin chẩn đoán (Diagnosis segment – DG1) . 63

2.4.7. Đoạn thông tin bảo hiểm (Insurance segment – IN1). 67

CHƯƠNG 3: PHẦN THỰC HÀNH: CHƯƠNG TRÌNH MessageHL7 v1.0.1

3.1. Giới thiệu chương trình “ĐỌC VÀ TẠO BẢN TIN HL7” . 70

3.2. Yêu cầu hệ thống. 71

3.3. Sử dụng chương trình. 71

3.4. Trợ giúp chương trình . 74

3.5. Bàn luận về chương trình . 75

CHƯƠNG 4: KẾT LUẬN VÀ HƯỚNG PHÁT TRIỂN

4.1. Kết luận . 77

4.2. Khả năng và hướng phát triển . 78

TÀI LIỆU THAM KHẢO. 79

PHỤ LỤC

PHỤ LỤC A – BẢNG HL7 VÀ NGƯỜI DÙNG ĐỊNH NGHĨA. 80

PHỤ LỤC B – LOẠI BẢN TIN . 98

PHỤ LỤC C – CÁC ĐOẠN CỦA BẢN TIN . 101

PHỤ LỤC D – MÃ NGUỒN CHƯƠNG TRÌNH . 105

pdf113 trang | Chuyên mục: Hệ Thống Thông Tin Y Tế | Chia sẻ: tuando | Lượt xem: 305 | Lượt tải: 0download
Tóm tắt nội dung Luận văn Nghiên cứu chuẩn HL7 dùng trao đổi dữ liệu điện tử trong y khoa và xây dựng chương trình đọc bản tin HL7, để xem tài liệu hoàn chỉnh bạn click vào nút "TẢI VỀ" ở trên
(goal-oriented) 
PPP Patient pathway message (problem-oriented) 
SVTH: VÕ THANH HOÀNG 98 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Message Description 
PPR Patient problem message 
PPT Patient pathway goal-oriented response 
PPV Patient goal response 
PRR Patient problem response 
PTR Patient pathway problem-oriented response 
QCK Deferred query 
QRY Query, original mode 
R0R Pharmacy/treatment order response 
RAR Pharmacy/treatment administration information 
RAS Pharmacy/treatment administration message 
RCI Return clinical information 
RCL Return clinical list 
RDE Pharmacy/treatment encoded order message 
RDO Pharmacy/treatment order message 
RDR Pharmacy/treatment dispense information 
RDS Pharmacy/treatment dispense message 
REF Patient referral 
RER Pharmacy/treatment encoded order information 
RGR Pharmacy/treatment dose information 
RGV Pharmacy/treatment give message 
RPA Return patient authorization 
RPI Return patient information 
RPL Return patient display list 
RPR Return patient list 
RQA Request patient authorization 
RQC Request clinical information 
RQI Request patient information 
RQP Request patient demographics 
RQQ Event replay query 
RRA Pharmacy/treatment administration acknowledgement message 
RRD Pharmacy/treatment dispense acknowledgment message 
RRE Pharmacy/treatment encoded order acknowledgment message 
RRG Pharmacy/treatment give acknowledgment message 
RRI Return referral information 
RRO ORR message for pharmacy/treatment 
SIU Schedule information unsolicited 
SPQ Stored procedure request 
SVTH: VÕ THANH HOÀNG 99 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Message Description 
SQM Schedule query message 
SQR Schedule query response 
SRM Schedule request message 
SRR Scheduled request response 
SUR Summary product experience report 
TBR Tabular data response 
UDM Unsolicited display update message 
VQQ Virtual table query 
VXQ Query for vaccination record 
VXR Vaccination record response 
VXU Unsolicited vaccination record update 
VXX Response for vaccination query with multiple PID matches 
SVTH: VÕ THANH HOÀNG 100 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
PHỤ LỤC C – CÁC ĐOẠN CỦA BẢN TIN 
Segment Description 
ACC Accident segment 
ADD Addendum segment 
AIG Appointment information - general resource segment 
AIL Appointment information - location resource segment 
AIP Appointment information - personnel resource segment 
AIS Appointment information - service segment 
AL1 Patient allergy information segment 
APR Appointment preferences segment 
ARQ Appointment request segment 
AUT Authorization information segment 
BHS Batch header segment 
BLG Billing segment 
BTS Batch trailer segment 
CDM Charge description master segment 
CM0 Clinical study master segment 
CM1 Clinical study phase master segment 
CM2 Clinical study schedule master segment 
CSP Clinical study phase segment 
CSR Clinical study registration segment 
CSS Clinical study data schedule segment 
CTD Contact data segment 
CTI Clinical trial identification segment 
DB1 Disability segment 
DG1 Diagnosis segment 
DRG Diagnosis related group segment 
DSC Continuation pointer segment 
DSP Display data segment 
EQL Embedded query language segment 
ERQ Event replay query segment 
ERR Error segment 
EVN Event type segment 
FAC Facility segment 
FHS File header segment 
FT1 Financial transaction segment 
FTS File trailer segment 
SVTH: VÕ THANH HOÀNG 101 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Segment Description 
GOL Goal detail segment 
GT1 Guarantor segment 
IN1 Insurance segment 
IN2 Insurance additional information segment 
IN3 Insurance additional information, certification segment 
LCC Location charge code segment 
LCH Location characteristic segment 
LDP Location department segment 
LOC Location identification segment 
LRL Location relationship segment 
MFA Master file acknowledgment segment 
MFE Master file entry segment 
MFI Master file identification segment 
MRG Merge patient information segment 
MSA Message acknowledgment segment 
MSH Message header segment 
NCK System clock segment 
NK1 Next of kin / associated parties segment 
NPU Bed status update segment 
NSC Status change segment 
NST Statistics segment 
NTE Notes and comments segment 
OBR Observation request segment 
OBX Observation/result segment 
ODS Dietary orders, supplements, and preferences segment 
ODT Diet tray instructions segment 
OM1 General segment - fields that apply to most observations 
OM2 Numeric observation segment 
OM3 Categorical test/observation segment 
OM4 Observations that require specimens segment 
OM5 Observation batteries (sets) segment 
OM6 Observations that are calculated from other observations 
segment 
ORC Common order segment 
PCR Possible causal relationship segment 
PD1 Patient additional demographic segment 
PDC Product detail country segment 
SVTH: VÕ THANH HOÀNG 102 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Segment Description 
PEO Product experience observation segment 
PES Product experience sender segment 
PID Patient identification segment 
PR1 Procedures segment 
PRA Practitioner detail segment 
PRB Problem detail segment 
PRC Pricing segment 
PRD Provider data segment 
PSH Product summary header segment 
PTH Pathway segment 
PV1 Patient visit segment 
PV2 Patient visit - additional information segment 
QAK Query acknowledgment segment 
QRD Original-style query definition segment 
QRF Original style query filter segment 
RDF Table row definition segment 
RDT Table row data segment 
RF1 Referral information segment 
RGS Resource group segment 
ROL Role segment 
RQ1 Requisition detail-1 segment 
RQD Requisition detail segment 
RXA Pharmacy/treatment administration segment 
RXC Pharmacy/treatment component order segment 
RXD Pharmacy/treatment dispense segment 
RXE Pharmacy/treatment encoded order segment 
RXG Pharmacy/treatment give segment 
RXO Pharmacy/treatment order segment 
RXR Pharmacy/treatment route segment 
SCH Schedule activity information segment 
SPR Stored procedure request definition segment 
STF Staff identification segment 
TXA Transcription document header segment 
UB1 UB82 data segment 
UB2 UB92 data segment 
URD Results/update definition segment 
URS Unsolicited selection segment 
SVTH: VÕ THANH HOÀNG 103 GVHD: TS. HUỲNH QUANG LINH 
www.bme.vn
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Segment Description 
VAR Variance segment 
VTQ Virtual table query request segment 
SVTH: VÕ THANH HOÀNG 104 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
PHỤ LỤC D – MÃ NGUỒN CHƯƠNG TRÌNH 
Chương trình được cung cấp với mã nguồn mở miễn phí với mong muốn mở rộng 
và nâng cao để chương trình ngày càng hoàn thiện và tốt hơn, tác giả luôn đón chờ 
mọi góp ý và hỗ trợ của mọi người. Phần mã nguồn này được xây dựng cùng các 
Forms, đi kèm theo đĩa chứa chương trình MessageHL7 v1.0.1, yêu cầu phải có 
chương trình Microsoft Visual Basic 6.0 để mở file messageHL7.vbp. 
Sau đây là đoạn mã ví dụ việc đọc các trường trong đoạn mào đầu (MSH) của bản 
tin HL7 hiển thị ra textbox. 
‘thủ tục gọi tập tin HL7 
Function OpenFile(Browse As String) 
 On Error GoTo error 
Dim sFile As String 
‘dùng commond dialog để duyệt file 
With dlgCommonDialog 
 .DialogTitle = "Open" 
 .CancelError = True 
 .FileName = Browse 
 .Filter = "HL7 Files (*.HL7)|*.HL7" 
 .ShowOpen 
 If Len(.FileName) = 0 Then 
 Exit Function 
 End If 
 sFile = .FileName 
 GlobalFile = sFile 
 End With 
 ReadMessageHL7 (sFile) 
 error: 
End Function 
‘thủ tục ReadMessageHL7 để đọc file HL7 
Private Sub ReadMessageHL7(sFile As String) 
 On Error GoTo error 
 ReadMSHsegment (sFile) 
 ReadEVNsegment (sFile) 
 ReadPIDsegment (sFile) 
 ReadNK1segment (sFile) 
 ReadPV1segment (sFile) 
 ReadDG1segment (sFile) 
 ReadIN1segment (sFile) 
error: 
End Sub 
‘Ví dụ thủ tục đọc đoạn MSH của bản tin 
SVTH: VÕ THANH HOÀNG 105 GVHD: TS. HUỲNH QUANG LINH 
LVTN: NGHIÊN CỨU CHUẨN HL7 VÀ XÂY DỰNG CT ĐỌC BẢN TIN HL7 TRƯỜNG ĐH BK TP.HCM 2007 
Private Sub ReadMSHsegment(sFile As String) 
 Dim PosFieldSep(1 To 20) As Integer, i As Integer, j As 
Integer 
 Dim s As String 
 Dim fso As New FileSystemObject, fil As File, txtFile, 
ts As TextStream 
 Set fil = fso.GetFile(sFile) 
 Set ts = fil.OpenAsTextStream(ForReading) 
 s = ts.ReadLine 
 j = 0 
 If (Left(s, 3) = "MSH") And (Right(s, 4) = "") Then 
 For i = 1 To Len(s) 
 If Mid(s, i, 1) = "|" Then 
 j = j + 1 
 PosFieldSep(j) = i 
 End If 
 Next 
 txtSendingApplicationMSH.Text = ReadField(s, 
PosFieldSep, 2) 
 txtSendingFacilityMSH.Text = ReadField(s, 
PosFieldSep, 3) 
 txtReceivingApplicationMSH.Text = ReadField(s, 
PosFieldSep, 4) 
 txtReceivingFacilityMSH.Text = ReadField(s, 
PosFieldSep, 5) 
 txtDateTimeOfMessageMSH.Text = 
readDateTime(ReadField(s, PosFieldSep, 6)) 
 txtDateTimeOfMessageMSH2.Text = ReadField(s, 
PosFieldSep, 6) 
 txtMessageControlIDMSH.Text = ReadField(s, 
PosFieldSep, 9) 
 Else 
 MsgBox "Khong phai ban tin HL7", vbOKOnly + 
vbExclamation, "Doc ban tin" 
 Exit Sub 
 End If 
End Sub 
‘thủ tục ReadField dùng trong thủ tục ReadMSHsegment 
Private Function ReadField(s As String, pos() As Integer, i 
As Integer) As String 
 If pos(i) 0 Then 
 ReadField = Mid(s, pos(i) + 1, (pos(i + 1) - 1) 
- pos(i)) 
 Else 
 ReadField = "" 
 End If 
End Function 
SVTH: VÕ THANH HOÀNG 106 GVHD: TS. HUỲNH QUANG LINH 
www.bme.vn

File đính kèm:

  • pdfluan_van_nghien_cuu_chuan_hl7_dung_trao_doi_du_lieu_dien_tu.pdf