« Return to Thread: Indexing distinct-values?

Re: Indexing distinct-values?

by George Feinberg-3 :: Rate this Message:

Reply (Restricted by the Administrator) | Reply to Author | View in Thread

Chris,

>> I'm afraid, this is not that case. Chris would need to return  
>> whole index,
>> if I understood his problem well. Without DBXML_INDEX_NODES (and  
>> assuming
>> that each document has a category element) it would result in  
>> returning
>> whole container, which could be very large. With INDEX_NODES he  
>> would get
>> only probably much smaller list of nodes, which would be faster.
>
> As a quick follow up, I tried Pavel's suggestion using INDEX_NODES and
> doing index queries. These cut the query time in half, but it was  
> still
> too long, upwards of ten seconds for around two thousand small  
> documents.

What do you mean by "index queries?"
Are you using XmlIndexLookup?
That would be your best alternative at this point.  You mentioned
an issue with XmlValue in a previous email, but didn't fully explain.

>
> From the list of nodes I cut out the text and used PHP functions to
> find the distinct values. I could have cut some time off by looking  
> up the number of distinct indexes and ending the search when that  
> number is reached, but that wouldn't help enough with this dataset.
>
> I'll have to keep a separate list of values in a different  
> document, which is disappointing. dbxml can immediately indicate  
> how many distinct key values there are which suggests to me that it  
> should know internally what these distinct values are. Not that I  
> know anything of its internals...

The number of distinct key values is maintained as a statistic for
optimization purposes; however, the information is
not currently available in a form that helps the actual evaluation.

Regards,

George



------------------------------------------
To remove yourself from this list, send an
email to xml-unsubscribe@...

 « Return to Thread: Indexing distinct-values?

LightInTheBox - Buy quality products at wholesale price!