[Xapian-discuss] Search using Terms and Prefix
Aleph Thomas
alepht at gmail.com
Wed Nov 14 15:33:50 GMT 2007
You are right, I using boolean and receive, that results, only if I search
for example mime:pdf not receive any think, I not can make searchs in the
terms?, for example if I have a title and need search in it?
thanks
mime:application/pdf Parsed query is: Xapian::Query(0 * Tapplication/pdf)
2 results found:
1: 100% docid=1474 [url=/strigi-0.5.7/testdata/data/simplepdf.pdf
sample=This is 12-point Times. This sentence will appear near the top of
page one. This is 24-point Times, appearing at the middle of page two.
caption=TwoPage PDFfile.pdf type=application/pdf modtime=1193401549
size=1760]
2: 100% docid=1548 [url=/xapian-bindings-1.0.4/apidoc.pdf sample=xapian-core
Reference Manual 1.0.4 Generated by Doxygen 1.5.2 Tue Oct 30 05:53:46 2007
Contents 1 xapian-core Namespace Index 1.1 2 xapian-core Namespace List . .
. . . . . . . . . . . . . . . . . . . . 1 1 3 3 5 5 7 7 9 9 11 11 23 23 28
32 35 44 46 52 63 65 xapian-core Hierarchical Index 2.1 xapian-core Class
Hierarchy . . . . . . . . . . . . . . . . . . . . . . 3 xapian-core Class
Index 3.1 xapian-core Class List . . . . . . . . . . . . . . . . . . . . . .
. . . . 4 xapian-core File Index 4.1 xapian-core ... type=application/pdf
modtime=1194458530 size=1812197]
On Nov 14, 2007 10:23 AM, James Aylett <james-xapian at tartarus.org> wrote:
> On Wed, Nov 14, 2007 at 10:17:54AM -0500, Aleph Thomas wrote:
>
> > I am consulting the DB made by omega from PHP, then I need recovery all
> the
> > files that are pdf and talk about omega for example, my query is:
> >
> > $query_string = "mime:pdf/ AND omega";
> > ...
> > $qp->add_prefix("mime", "T");
> > ...
> >
> > Then I not receive any results, and have files application/pdf indexed,
>
> You won't. The term generated is (or should be) Tapplication/pdf - try
> adding it as a boolean term. add_boolean_prefix not add_prefix? Sorry,
> I know what I mean, but I'm too rushed right now to figure out if this
> is the right approach. But your problem is the construction of the term.
>
> J
>
> --
>
> /--------------------------------------------------------------------------\
> James Aylett xapian.org
> james at tartarus.org uncertaintydivision.org
>
> _______________________________________________
> Xapian-discuss mailing list
> Xapian-discuss at lists.xapian.org
> http://lists.xapian.org/mailman/listinfo/xapian-discuss
>
More information about the Xapian-discuss
mailing list