search for: add_boolean_term

Displaying 12 results from an estimated 12 matches for "add_boolean_term".

2013 Oct 13
2
trouble with user's right indexing with omega
..." dbb/ term `I at ftp' not in database That's wrong, user "ftp" can read this file. As this user is not in "users" group, this user cannot find this file. In omindex.cc, if I comment "inc_tag_added": if (group) { newdocument.add_boolean_term(string("I#") + group); //inc_tag_added = true; } all is ok: # delve -t "I at ftp" dbb/ Posting List for term `I at ftp' (termfreq 1, collfreq 0): 1 Why user's right are ignore when group has read right in the file? Is a normal behavior or a...
2011 Aug 09
3
what is the fastest way to fetch results which are sorted by timestamp ?
what is the fastest way to fetch results which are sorted by timestamp ? i want to use xapian as my search engine , use add_boolean_term(something) and add_value(0,sortable_serialise(get_timestamp())) to a doc. search through enquire.set_weighting_scheme(xapian.BoolWeight()) and enquire.set_sort_by_value(0,True) to ensure that the results are sorted by the timestamp. This method is ok , but is there a faster way to do that ? Si...
2010 Apr 15
1
Xapian 1.0.19 released
...u can download from: http://xapian.org/download The most notable changes in this release are: QueryParser: * Fix memory leak if Database throws an exception during parsing. Flint backend: * Updating positional information for a document optimised a little. Search::Xapian: * Wrap Document::add_boolean_term() (added to C++ API in 1.0.18). The full lists of user-visible changes are linked to from here, and from the "[news]" links on the download page: http://trac.xapian.org/wiki/ReleaseOverview/1.0.19 As always, if you encounter problems, please report them here, or to the bug-tracker: ht...
2017 Jan 04
0
Formulating Advanced Queries with Xapian-Omega
...em as a filter > > term > > It is no doubt due to my lack of understanding but how would this > interesting option 'pulling them out at index time ...' be implemented > ? For example in Perl, at index time: while ($text =~ /(\b\d-\d{3}-\d{5}-[\dX]\b)/g) { $doc->add_boolean_term("XISBN$1"); } With this approach, you could also easily do additional validation (such as checking the check digit for codes which have one, as ISBNs do). Then at query time: $queryparser->add_boolean_prefix("isbn", "XISBN"); Then the user can use isbn:...
2018 Mar 30
2
sorting large msets
...mp, $flag); my $n = shift || 100; for my $i (0..$n) { $xdb->begin_transaction; for my $j (0..2000) { my $doc = Search::Xapian::Document->new; my $num = Search::Xapian::sortable_serialise(($i * 1000) + $j); $doc->add_value(0, $num); $doc->set_data("$i $j"); $doc->add_boolean_term('T' . 'mail'); $xdb->add_document($doc); $doc = Search::Xapian::Document->new; $doc->add_value(0, $num); $doc->set_data("$i $j"); $doc->add_boolean_term('T' . 'ghost'); $xdb->add_document($doc); } $xdb->commit_transaction...
2014 Jan 27
4
Perl Search::Xapian
...9;XD'); # index fields without prefixes for general search. $tg->index_text($title); $tg->increase_termpos(); $tg->index_text($description); # Store all the feilds for display purposes. # this is a TODO my $idterm = "Q".$identifier; $doc->add_boolean_term($idterm); $db->replace_document($idterm, $doc); } close $fh; ----------------snip--------------- (\ /) ( . .) Jon's website is here: c(")(") http://www.securityrabbit.com
2016 Dec 29
2
Formulating Advanced Queries with Xapian-Omega
To Olly Betts: Thank you very much for any feedback. I apologise for this belated reply and also for the fact that the text of the previous posting appeared fragmented, due to its fixed chars/line format. With reference to: > Can, or could, one construct a query so that Omega (Xapian) can handle > this ? > > ... perhaps with some type of Regex ? > > It would seem
2018 Feb 27
1
modifying the DB while iterating is user error, right?
Hello, I noticed a problem with DatabaseCorruptError exceptions with public-inbox and I guess it's user error... The problem is public-inbox was calling replace_document to modify the DB while iterating through a PostingIterator. At first I thought it was a glass problem, but I've hit it with chert on my dataset, too. I have a standalone Perl script to reproduce the problem at
2013 Sep 22
2
How to filter search result with query with has white space.
...et_stemmer(stemmer); Xapian::Document doc; doc.set_data(d.title); indexer.set_document(doc); indexer.index_text(d.title,1,"title"); indexer.index_text(d.content,1,"content"); indexer.index_text(d.url,1,"url"); doc.add_boolean_term("title"+d.title); db.replace_document(d.url,doc); db.commit(); } catch (const Xapian::Error &e) { std::cout << e.get_description() << std::endl; exit(1); }} void searchData(std::string query_string){ try{ Xapian::Database...
2013 Sep 22
2
How to filter search result with query with has white space.
...et_stemmer(stemmer); Xapian::Document doc; doc.set_data(d.title); indexer.set_document(doc); indexer.index_text(d.title,1,"title"); indexer.index_text(d.content,1,"content"); indexer.index_text(d.url,1,"url"); doc.add_boolean_term("title"+d.title); db.replace_document(d.url,doc); db.commit(); } catch (const Xapian::Error &e) { std::cout << e.get_description() << std::endl; exit(1); }} void searchData(std::string query_string){ try{ Xapian::Database...
2016 Jul 24
3
Xapian 1.4.0 released
On Fri, Jul 22, 2016 at 07:19:43PM -0700, Kevin Duraj wrote: > I would like to propose to change the following code while indexing a > term that is larger than 245 characters and then crashing and aborting > the entire index, we could rather truncate the term to 245 characters > and continue with indexing. Kevin -- I wonder what others are currently doing when this comes up (or if
2011 Aug 11
3
Fwd: Re: what is the fastest way to fetch results which are sorted by timestamp ?
...ent matches have been > > found. It can be very awkward to get an index in such order though, > > particularly in the face of updates, assuming that you want the sort > > order to show most recent first. > > > > > i want to use xapian as my search engine , use > add_boolean_term(something) and > add_value(0,sortable_serialise(get_timestamp())) to a doc. > > > search through enquire.set_weighting_scheme(xapian.BoolWeight()) and > enquire.set_sort_by_value(0,True) to ensure that the results are sorted by > the timestamp. > > > > That's anoth...