[Xapian-discuss] find document by doc path

Clemens Zeidler clemens.zeidler at rwth-aachen.de
Mon Nov 19 18:42:18 GMT 2007


Hi,

I want to update a document. The document is identified by the document
path e.g. /home/user/file.txt. To find the doc id by the path I need to
assign the path to the document. In the FAQ is supposed to add the doc id
(the path) as a term to the document.

My idea is to at the path as a value by

#define PATH_ID 0
add_value(PATH_ID, "/home/user/file.txt")

and then do a query:

Query (Query::op op_, PATH_ID, "/home/user/file.txt",
"/home/user/file.txt")

Is there a drawback to do such a query on a value? Or is a query on a
value even faster?

thank you
	Clemens

-- 
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/



More information about the Xapian-discuss mailing list