lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <e...@ehatchersolutions.com>
Subject Re: QueryParser refactoring
Date Wed, 09 Mar 2005 14:16:42 GMT

On Mar 9, 2005, at 7:25 AM, sergiu gordea wrote:
> transformations to be reversible
> (I mean something like Query => String => Query, with the constraint 
> initial query equals final query).
>
> Ok ... I give up ... if  this feature is to hard to be implemented, 
> the soltution will be to work around in my source code to make it 
> work.

It's not just hard, its impossible in the generalizable sense.  An 
analyzer is involved in parsing a query and could easily 
remove/change/add to the query.  I suspect there are probably issues 
with escaped characters as well.  For many cases with a straightforward 
analyzer and queries that use alphabetic terms then it'll probably work 
fine as you've seen, but relying on Query.toString is risky.

	Erik


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


Mime
View raw message