Re: [bdbxml] Indexing attributes
George Feinberg <[email protected]>
| Newsgroups | gmane.comp.db.dbxml.general |
|---|---|
| Message-ID | <[email protected]> |
On Jul 29, 2005, at 6:11 AM, Peter Hickman wrote: [...] >> Could it be that your paragraphs are always numbered (with >> @number) in document order? If so, then you can leave off the >> "order by" clause, as this is probably the main reason for the >> query being slow right now. >> > > Problem is that the data is not necessarily in the correct order. I > am thinking of writing an XSLT to reorder the documents before > feeding them into the database. > > I tested a version of the query without the order by clause and the > saving was 6 ms (yes milliseconds). > > However changing from > > createContainer books.dbxml d novalidate > > to > > createContainer books.dbxml in novalidate > > has reduced the query time by an order or magnitude, and the > removal of the order by clause has saved another 37 ms. Using a node storage container is almost always better for query speed, regardless of document size, and has a major effect (as you have seen) on large documents. Node storage is the default type for the API methods that create containers, but is is *not* the default type for the dbxml shell program. We are considering changing that. Regards, George ------------------------------------------ To remove yourself from this list, send an email to [email protected]