A method of searching a document having nested-structure document-specific
markup (such as Extensible Markup Language (XML)) involves 112 receiving
a query that designates at least (A) a phrase to be matched in a phrase
matching process, and (B) a selective designation of at least a tag or
annotation that is to be ignored during the phrase matching process. The
method further involves 114 deriving query-specific indices based on
query-independent indices that were created specific to each document,
and 116 carrying out the phrase matching process using the query-specific
indices on the document having the nested-structure document-specific
markup.