Lists Home |
Date Index |
Elliotte Harold wrote:
> Ken North wrote:
>> When you store a document in a text column, it's searchable using SQL
>> Those queries use the indexing capabilities of software such as Oracle
>> interMedia Text Cartridge, DB2 Text Extender and Microsoft Search
> Yes, but suppose I want to find all occurrences of the string "Now is
> the time for all good men to come to the aid of their country." XML
> unaware full text search would not normally find "<strong>Now</strong>
> is the time for all good men to come to the aid of their country."
> More importantly, if I have XML data then I normally want to use the
> markup to delimit and index the searches. For instance, I might want to
> find all prescriptions of Xanax with a dosage of 5mg, not all
> occurrences of the word "Xanax" somewhere near the text "5mg". If we're
> just storing everything in a CLOB, we might as well be using flat files.
> The markup has meaning. It should be used to inform and optimize the
You can use Lucene and pass XML documents through a DefaultHandler. For
example, we have fields for just the text nodes and some of the more
interesting elements like internal links, external links, glossery
items, etc... and metadata like who created it, who modified it last,
created date, last modified, etc... It is rather extensive for us
because of the way we use XML to configure a site/folder/page/content
piece. It works very well and is extremely fast.
(I have been thinking you could use Lucene to create a fast, read only
XML DB. Updating /requires/ you to delete a lucene document, reindex and
We currently keep everything in the filesystem, but the same concepts
could be used for XML stored in a DB.