dbTalk Databases Forums  

Indexing metadata in BDBXML

comp.databases.berkeley-db comp.databases.berkeley-db


Discuss Indexing metadata in BDBXML in the comp.databases.berkeley-db forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Erik Braten
 
Posts: n/a

Default Indexing metadata in BDBXML - 10-08-2003 , 10:49 AM






Hi!

Just a newbie question. I apologise if it has been answered earlier.
Is it possible to add indexes for the metadata attributes of the documents?
I've been trying to do this, but the query optimizer doesn't seem to use the
index. I'm trying to make a temporal (timerelated) database. Each document
will be valid for a given period of time, and this information is stored as
two metadata attributes, start and stop, for each document. I'm then running
a query to check for documents valid at time T. This query would look like
this in XPath: "//*//@time:start<='T' and //*//@time:stop>'T' ". (time is
the prefix for the two attributes).
I have added an index for the start attribute with the following call to
addIndex:
addIndex("http://erik.com", "start", "node-attribute-equality-number");
Where "http://erik.com" is the namespace used when setting the metadata. A
similar index has been set for stop.
So the question is, if it is possible to index metadata, what am I doing
wrong?

Thanks in advance
Regards,
Erik Bråten



Reply With Quote
  #2  
Old   
John Merrells
 
Posts: n/a

Default Re: Indexing metadata in BDBXML - 10-09-2003 , 10:40 AM







Erik Braten wrote:
Quote:
this in XPath: "//*//@time:start<='T' and //*//@time:stop>'T' ". (time is
The inequality operators are only supported for Numbers in
XPath 1.0. 'T' is a String, rather than a Number, so just
say T and you'll be OK.

John



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.