Re: filtering by docid range?
Matthew Somerville <[email protected]> Fri, 12 Feb 2021 08:43:38 +0000
| Newsgroups | gmane.comp.search.xapian.general |
|---|---|
| Message-ID | <CAKs8PY2sR5BBE2FJwCjecr7LF3eJgrt6zK+n2egsMRn5sAwBug@mail.gmail.com> |
Just for interest, dunno if helpful (or a good way of doing it!), what we do (for email alerting) is record an incrementing batch number B123 with each indexing pass of data, and then for an alert run only search for results with batch numbers since the last alert run. ATB, Matthew On Mon, 8 Feb 2021 at 18:07, Eric Wong <[email protected]> wrote: > > Hey all, is there a way to exclude results by docid? > > I'm using a combined DB and guaranteeing the order for > ->add_database calls. All sub DBs have monotonically > increasing docids, so the combined docid will remain > monotonically increasing. > > I'll store the maximum docid from a previous search ($OLD_MAX), > and it would be nice to have Xapian only could return results it > hasn't returned before. Otherwise, I'll continue using: > > set_weighting_scheme(BoolWeight->new) > set_docid_order(ENQ_DESCENDING) > > ...and stop iterating mset retrieval once $docid < $OLD_MAX > > I'm using Perl Search::Xapian from Debian stable (buster). > > Thanks >