Patent ID: 7287023

Claim:
A method of answering an XML query, comprising: receiving an XML query; transforming the XML query into a structure-encoded sequence; searching a virtual suffix tree (ViST) structure using the structure-encoded sequence and returning one or more document IDs, wherein searching a ViST structure using the structure encoded sequence, comprises: (a) assuming the query sequence is <q.sub.-1, q.sub.-2, . . . , q_n>; (b) assigning. i=1,begin=0,end=infinity; (c) searching a D-Ancestor B+Tree using key q_i, which returns an S-Ancestor B+Tree; and (d) performing a range search (begin,end) on the S-Ancestor B+Tree, wherein performing the range search comprises: (e) returning a set of ranges (x.sub.-1,y.sub.-1), . . . , (x_n,y_n); (f) for each (x_i,y_i) doing (g) and (h); (g) if (i=n) then performing a range query (x_i,y_i) on the doc-ID index and returning one or more document IDs; (h) if (i<n) then assigning i=i+1; begin=x_i, end=y_i; going to (c).