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 Hendrik Haddorp <he...@gmx.net> on 2017/07/20 20:56:19 UTC
field:* vs field:[* TO *]
Hi,
I had already asked this on the Solr mailing list but would like to
confirm this here:
If I want to query all documents that have a field or do not have a
field does it really perform better to use "field:[* TO *]" instead of
"field:*" ? I would have expected that Lucene handles both queries
internally the same and is not really expanding the wildcard to all
possible tokens.
regards,
Hendrik
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: field:* vs field:[* TO *]
Posted by Adrien Grand <jp...@gmail.com>.
This is going to depend on the queryparser that you are using and the field
type of `field`. I agree both should be handled as efficiently.
Le jeu. 20 juil. 2017 à 22:56, Hendrik Haddorp <he...@gmx.net> a
écrit :
> Hi,
>
> I had already asked this on the Solr mailing list but would like to
> confirm this here:
>
> If I want to query all documents that have a field or do not have a
> field does it really perform better to use "field:[* TO *]" instead of
> "field:*" ? I would have expected that Lucene handles both queries
> internally the same and is not really expanding the wildcard to all
> possible tokens.
>
> regards,
> Hendrik
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>