search for: set_queri

Displaying 20 results from an estimated 27 matches for "set_queri".

Did you mean: set_query
2005 Feb 24
2
mutable Query objects
There's a bit of an API glitch with Query objects at present. This code shows it off: Xapian::Database("/path/to/db"); Xapian::Enquire enquire(db); // make a simple query Xapian::Query myquery(Xapian::Query::OP_NEAR, phrase, phrase + 2); enquire.set_query(myquery); // Now change the query - this shouldn't affect the query enquire // will run, but it does.
2013 Oct 23
2
performance on document.get_data()
I got some performance issue for document.get_data() and enquire.get_mset(). It costs 35 seconds for matches = enquire.get_mset(0,200), and 3 seconds for iterating all doc in matches to get_data. Is't normal? My index contains 30millions documents. I use python binding to operate xapian. Bellow it's my index structure # value: 0:date, 1:site # data: json message which contains: author,
2010 Oct 21
2
In-memory databases vs PHP Bindings
I can't quite connect the dots on this, perhaps someone can help. I'm simply trying to create an in-memory database comprising a single document, so that I can run a load of queries against it and see if any of them match the new document (this is to enable users to have 'subscriptions' to saved searches and be alerted every time a new item is published that matches their
2006 Dec 06
1
Bug and patch for +terms with wildcards
In current Xapian SVN HEAD, there is a bug in the query parser concerned with the handling of wildcard terms with a "+" prefix. Specifically, a query such as "+foo* bar" will be parsed by the query parser into Xapian::Query("bar") if there are no terms in the database which start "foo". Instead, since the "+" term cannot be matched, I believe
2008 Sep 27
3
Query::MatchAll
Why there still been rank when using Query::MatchAll() ?
2007 Mar 29
1
"Bad serialised query" error
Hi all, We've struck a problem when using remote queries and hoping someone can offer some guidance. I haven't managed to get a C++ reproduction in the test suite, but I have got a demo that fails using Python: import xapian db = xapian.remote_open('localhost', 8100) qp = xapian.QueryParser() qp.set_database(db) query = qp.parse_query('test') enq =
2007 Feb 02
1
Working demo of search engine using boolean query.
Lately I was reading many articles about using boolean queries for search engine but I haven't seen any complete working demo. Therefore I put together very simple working demo of search engine using boolean query. Feel free to suggest any performance improvement or error while keeping it as simple as possible for understanding. Thanks, -Kevin Duraj http://myhealthcare.com
2009 Mar 02
0
Xapian, PHP bindings and
Hello, With PHP, I try to get spelling corrections but after 2 days of trying I can make it work !!! Here is my < simple > code : <?php require_once( '../global.info.php' ); require_once( 'xapian.class.php' ); require_once( 'xapianencode.func.php' ); // Open the database for searching. try { $database = new XapianDatabase(
2009 Aug 17
1
Xapian DatabaseError
Hi, I've a problem to integrate xapian in my web application. I've developed the code for index e for search the documents published through my application. The app is developed in PHP. I've created a file that contain some function for search (called simpleSearch and advSearch). The problem is that if i run the code through the IDE (Zend for Eclipse) as PHP script it work correctly,
2011 Aug 10
0
xapian enquire.set_docid_order(Xapian::Enquire::DESCENDING so slow!
i have 300 millions records and my search file like this , i want the newest 10 results that match my query , so i use boolean search and "enquire.set_docid_order(enquire.DESCENDING)" , but this method seems a little slow . when i remove "enquire.set_docid_order(enquire.DESCENDING)" it run much faster . how can i fetch the newest 10 results as fast as possible? search.py
2012 Nov 03
1
get the title from the document
Dear all, I am working on a very simple project, in which I wanna get the title from the document. For instance, this is what I have done so far. ///////////// code? for building the index file ??????? # Load content ??????? content = open(filePath).read() ??????? # Prepare document ??????? document = xapian.Document() ??????? document.set_data(content) ??????? # Store fileName ???????
2013 Jun 19
2
Compact databases and removing stale records at the same time
I'm trying to compact (or at least merge) multiple databases, while stripping search records which are no longer required. Backstory: I've inherited the Cyrus IMAPd xapian-based search code from Greg Banks when he left Opera. One of the unfinished parts was removing expunged emails from the search database. We moved from having a single search database to supporting multiple
2018 Jun 21
0
Welcome to the "Xapian-discuss" mailing list
Please keep replies on the mailing list — more people can help (and benefit) that way :) So OP_NEAR looks for its terms close to each other (hence "near"). The window is how far away they can be. Probably the easiest way to play with this is using the NEAR syntax in the query parser. So if you had a plain text document: I am walking, always walking. And index it in a very simple
2007 Feb 09
1
PHP Binding and dbi2omega questions
Hi All, I've installed Xapian and the php module. I've set up a script for use with scriptindex and dbi2omega for getting data from the db into the index easily, the script file is as follows: =============================== id : field=id title : index title: field=title description : index description : truncate=50 field=content ============================= However, when querying
2014 Mar 26
3
about sort_by_value
Hello, I have found that the use of sort_by_value very slow. 16800 result, return to the previous 10, sorting takes about 25ms. And if you do not sort, returns 10, need only about 0.3ms. How to make the sort faster? -------------- next part -------------- An HTML attachment was scrubbed... URL:
2015 Jan 16
2
Question on "single writer, multiple reader"
Hi, dear Xapianers! I've been using Xapian in my project recently. The feature "single writer, multiple reader" is one of my favorite, but currently I can't make it work. My goal is to add more documents to the database increamentally, while the Xapian search process is not stopped. I followed "quickstartindex.cc" and "quickstartsearch.cc" on
2013 Jul 03
2
Potential memory leak when assigning MSetItem values
I've traced a memory leak to a statement which assigns the values from an MSetItem to a dictionary which is then appended to a list in python. We're running python 2.7.3, xapian-core 1.2.15 and xapian-bindings 1.2.15. I've provided an example which reproduces the behavior below. The example prints the PID and has a few statements waiting for input to make observing the behavior easier.
2013 Sep 22
2
How to filter search result with query with has white space.
Hello, include <iostream>#include <string>#include <xapian.h>struct document{ std::string title; std::string content; std::string url;}; void indexData(document d) { try { Xapian::WritableDatabase db("/Users/ramesh/Desktop/xapian", Xapian::DB_CREATE_OR_OPEN); Xapian::TermGenerator indexer; Xapian::Stem
2013 Sep 22
2
How to filter search result with query with has white space.
Hello, include <iostream>#include <string>#include <xapian.h>struct document{ std::string title; std::string content; std::string url;}; void indexData(document d) { try { Xapian::WritableDatabase db("/Users/ramesh/Desktop/xapian", Xapian::DB_CREATE_OR_OPEN); Xapian::TermGenerator indexer; Xapian::Stem
2015 Jul 26
1
Get term from document by position
mple (see attachment). > > Attachments get stripped out by the mailing list, so I?ve made a private gist of the two files here: <https://gist.github.com/jaylett/ce8455b37e2b84422346>. > > Actually, when I run it I get 0 matches, which would explain why you?re just getting the start of the document. However if I adjust things (match the stemming strategy for TermGenerator to