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 Mark Miller <ma...@gmail.com> on 2007/02/20 15:31:54 UTC

Neuter fields in query

I need to make a query specified with fields to be field care free when 
used against a memory index (every part of the query will match all 
fields). I am not holding my breath, but any ideas? Is the only way to 
deconstruct and reconstruct the query?

- Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Neuter fields in query

Posted by Mark Miller <ma...@gmail.com>.
Thanks for the info Erick. Unfortunately, I need to be able to do this 
with any old Query that is supplied to me...no access to the 'raw' query 
:( I also need the process to be relatively cheap which is why I don't 
wan to deconstruct and reconstruct.

- Mark

Erick Erickson wrote:
> Golleeee, Mark, it sounds like we're working on very similar projects 
> <G>. I
> solved something similar by storing the relevant parts of the original 
> query
> away ahead of time in a format suitable for using with the 
> MemoryIndex. It
> was lots easier to handle that way in my app, since I got in unfielded 
> data
> (entries on a form) that I had to map to one or more fields in my index
> anyway, so it was just pretty much the raw query. All the manipulations I
> had to do to make things work out (implied proximity and stemming with 
> exact
> matches etc....) were handled by throwing the raw query at the same
> parser/analyzer for the MemoryIndex that I used originally with (you 
> guessed
> it) no fields in the query and just letting it default to the only 
> field in
> my MemoryIndex.....
>
> Don't know if this helps or not.
>
> Best
> Erick
>
> On 2/20/07, Mark Miller <ma...@gmail.com> wrote:
>>
>> I need to make a query specified with fields to be field care free when
>> used against a memory index (every part of the query will match all
>> fields). I am not holding my breath, but any ideas? Is the only way to
>> deconstruct and reconstruct the query?
>>
>> - Mark
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>
>>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Neuter fields in query

Posted by Erick Erickson <er...@gmail.com>.
Golleeee, Mark, it sounds like we're working on very similar projects <G>. I
solved something similar by storing the relevant parts of the original query
away ahead of time in a format suitable for using with the MemoryIndex. It
was lots easier to handle that way in my app, since I got in unfielded data
(entries on a form) that I had to map to one or more fields in my index
anyway, so it was just pretty much the raw query. All the manipulations I
had to do to make things work out (implied proximity and stemming with exact
matches etc....) were handled by throwing the raw query at the same
parser/analyzer for the MemoryIndex that I used originally with (you guessed
it) no fields in the query and just letting it default to the only field in
my MemoryIndex.....

Don't know if this helps or not.

Best
Erick

On 2/20/07, Mark Miller <ma...@gmail.com> wrote:
>
> I need to make a query specified with fields to be field care free when
> used against a memory index (every part of the query will match all
> fields). I am not holding my breath, but any ideas? Is the only way to
> deconstruct and reconstruct the query?
>
> - Mark
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>