[Xapian-discuss] Prefix lowercasing

Matthew Somerville matthew at mysociety.org
Thu Feb 14 15:20:38 GMT 2008


Upgrade going well, the new (for us, anyway :) ) date range search is great.

The documentation at 
http://xapian.org/docs/apidoc/html/classXapian_1_1QueryParser.html says that 
a search for 'author:Orwell' becomes 'Aorwell', and 'a search for "site:Foo 
domain:Bar author:Fred" will map to "(Hfoo OR Hbar) AND Afred".'

I have the following document:

$ delve -r 854 searchdb
Term List for record #854: D20080122 Pcon [other terms snipped]

But performing a search for "party:Con" with the following code in PHP 
returns no results:

   $queryparser = new XapianQueryParser();
   $queryparser->add_boolean_prefix('party', 'P');
   $query = $queryparser->parse_query('party:Con');
   print $query->get_description(); # is "Xapian::Query(0 * PCon)"

Am I missing anything, or do I have to preprocess the query string to 
lowercase the boolean term provided?

ATB,
Matthew



More information about the Xapian-discuss mailing list