OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Database access question for HL7 data



"Rochester, Dean" wrote:

> > I have heard that oracle, DB2 and other databases already have XML
> > listeners or parsers built into them.  If we have HL7 messages, how can we
> > send them to these database parsers as XML data?  Can we do queries or
> > only updates to the databases?

The process varies depending on the database, but usually you will need
to first set up a map of some sort that tells the database how to store
the various bits of the HL7 message in the document. You can then call a
method that invokes the parser and stores the data according to the map.
(I believe this is generally possible over HTTP as well.)

Queries are also supported -- they just reverse the process. SQL Server
has a query language for this purpose; most other databases require you
to retrieve the data according to your mapping, then transform it with
XSLT if you want it in a format other than that used by the mapping.

The real problem here is with HL7 itself. If I recall correctly, this
has a lot of mixed content. The mapping of mixed content to relational
databases is messy and very inefficient[1]. Furthermore, I don't think
any XML-enabled databases support the storage of mixed content except as
a BLOB, and even if they do, I'm pretty sure that they don't store order
information, which is necessary to retrieve sibling text and elements in
the correct order.

Therefore, your choices are to: (1) store complete HL7 documents as
BLOBs and query them with various text tools which may or may not be
XML-aware, (2) store HL7 documents as BLOBs and index them with
side-tables[2], or (3) use a native XML database.
-- 
Ronald Bourret
XML, Databases, and Schemas
http://www.rpbourret.com
Speaker, Geek Cruises' XML Excursion '02

[1] http://www.xml.com/pub/a/2001/05/09/dtdtodbs.html?page=3#mixed
[2] http://www.rpbourret.com/xml/XMLAndDatabases.htm#simpledocstorage