RE: Querying multiple fields of a index

2002-04-04 Thread Aruna Raghavan

Hi,
I use a boolean query and add individual queries to it.

-Original Message-
From: Harpreet S Walia [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 04, 2002 10:13 AM
To: Lucene Users List
Subject: Querying multiple fields of a index


Hi,

Is it possible to query multiple fields of  a given index and get the result
based on this combined query.
i.e for example if  i want to serach for a word "lucene" in the title field
and the word "engine" in the summary filed and want the results based on
these words .

How can i achieve this ?

TIA

Regards
Harpreet



--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Querying multiple fields of a index

2002-04-04 Thread Peter Carlson

Hi,

If you are using the queryParser and the standardAnalyzer you would use a
querystring like


title:lucene AND summary:engine


So the pattern is :

Also, you don't have to explicitly put the field name if you are searching
the default field.  That is if title is the default field the search would
be 

lucene AND summary:engine

Hope this helps.


--Peter


On 4/4/02 8:13 AM, "Harpreet S Walia" <[EMAIL PROTECTED]> wrote:

> Hi,
> 
> Is it possible to query multiple fields of  a given index and get the result
> based on this combined query.
> i.e for example if  i want to serach for a word "lucene" in the title field
> and the word "engine" in the summary filed and want the results based on
> these words .
> 
> How can i achieve this ?
> 
> TIA
> 
> Regards
> Harpreet
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
> 
> 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Querying multiple fields of a index

2002-04-04 Thread Otis Gospodnetic

You can use MultipleFieldQueryParser class, included with Lucene.

Otis

--- Harpreet S Walia <[EMAIL PROTECTED]> wrote:
> Hi,
> 
> Is it possible to query multiple fields of  a given index and get the
> result
> based on this combined query.
> i.e for example if  i want to serach for a word "lucene" in the title
> field
> and the word "engine" in the summary filed and want the results based
> on
> these words .
> 
> How can i achieve this ?
> 
> TIA
> 
> Regards
> Harpreet
> 
> 
> 
> --
> To unsubscribe, e-mail:  
> 
> For additional commands, e-mail:
> 
> 


__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Querying multiple fields of a index

2002-07-09 Thread Mohamed Idrees

ok, the discussions are about passing some field names...

how about in situation where i don't have to pass any field name but
just do a complete search in all the fields...

hope someone can clarify



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


Re: Querying multiple fields of a index

2002-07-09 Thread Mohamed Idrees

First of all lemme ask sorry to the forum (lucene-user) and you Otis (in
particular) for the previous mail.

That was supposed to be addressed to our in-house forum inorder for my
team-mates to gain some knowledge.
Actually, I know how to achieve this.

Sorry for the trouble again.

Mohamed Idrees wrote:

> ok, the discussions are about passing some field names...
>
> how about in situation where i don't have to pass any field name but
> just do a complete search in all the fields...
>
> hope someone can clarify



--
To unsubscribe, e-mail:   
For additional commands, e-mail: