You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Senthil Kumar K <se...@trigent.com> on 2003/09/22 08:06:58 UTC
Is it possible in lucene for numeric search
Hi,
I found that lucene is a full-featured text search engine. Is it
possible to make it for numeric search. In my appl. I need to look
in to the index for score=75.
regards,
k.senthilkumar
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org
Re: Is it possible in lucene for numeric search
Posted by Terry Steichen <te...@net-frame.com>.
You can also use a RangeQuery. If you index the field of numeric data, say
'score', as a string, then you can do things like: score:[75 TO 80]. Only
extra work is that you need to pad the actual score with enough 0's (such
that 9 becomes 09, etc.) to cover the expected range.
Regards,
Terry
----- Original Message -----
From: "Erik Hatcher" <er...@ehatchersolutions.com>
To: "Lucene Users List" <lu...@jakarta.apache.org>
Sent: Monday, September 22, 2003 9:08 AM
Subject: Re: Is it possible in lucene for numeric search
> Yes, you can do numeric searches as long as you realize its really just
> text that is indexed. You will need to ensure the Analyzer you use
> indexes numbers appropriately as well.
>
> Erik
>
>
> On Monday, September 22, 2003, at 02:06 AM, Senthil Kumar K wrote:
>
> > Hi,
> >
> > I found that lucene is a full-featured text search engine. Is it
> > possible to make it for numeric search. In my appl. I need to look
> > in to the index for score=75.
> >
> > regards,
> > k.senthilkumar
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: lucene-user-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org
Re: Is it possible in lucene for numeric search
Posted by Terry Steichen <te...@net-frame.com>.
You can also use a RangeQuery. If you index the field of numeric data, say
'score', as a string, then you can do things like: score:[75 TO 80]. Only
extra work is that you need to pad the actual score with enough 0's (such
that 9 becomes 09, etc.) to cover the expected range.
Regards,
Terry
----- Original Message -----
From: "Erik Hatcher" <er...@ehatchersolutions.com>
To: "Lucene Users List" <lu...@jakarta.apache.org>
Sent: Monday, September 22, 2003 9:08 AM
Subject: Re: Is it possible in lucene for numeric search
> Yes, you can do numeric searches as long as you realize its really just
> text that is indexed. You will need to ensure the Analyzer you use
> indexes numbers appropriately as well.
>
> Erik
>
>
> On Monday, September 22, 2003, at 02:06 AM, Senthil Kumar K wrote:
>
> > Hi,
> >
> > I found that lucene is a full-featured text search engine. Is it
> > possible to make it for numeric search. In my appl. I need to look
> > in to the index for score=75.
> >
> > regards,
> > k.senthilkumar
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: lucene-user-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
>
Re: Is it possible in lucene for numeric search
Posted by Erik Hatcher <er...@ehatchersolutions.com>.
Yes, you can do numeric searches as long as you realize its really just
text that is indexed. You will need to ensure the Analyzer you use
indexes numbers appropriately as well.
Erik
On Monday, September 22, 2003, at 02:06 AM, Senthil Kumar K wrote:
> Hi,
>
> I found that lucene is a full-featured text search engine. Is it
> possible to make it for numeric search. In my appl. I need to look
> in to the index for score=75.
>
> regards,
> k.senthilkumar
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
Re: Is it possible in lucene for numeric search
Posted by Erik Hatcher <er...@ehatchersolutions.com>.
Yes, you can do numeric searches as long as you realize its really just
text that is indexed. You will need to ensure the Analyzer you use
indexes numbers appropriately as well.
Erik
On Monday, September 22, 2003, at 02:06 AM, Senthil Kumar K wrote:
> Hi,
>
> I found that lucene is a full-featured text search engine. Is it
> possible to make it for numeric search. In my appl. I need to look
> in to the index for score=75.
>
> regards,
> k.senthilkumar
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org