lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hoss Man (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SOLR-4485) Consider making QParsers throw SyntaxError if field being searched is not indexed
Date Thu, 21 Feb 2013 22:52:12 GMT

    [ https://issues.apache.org/jira/browse/SOLR-4485?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13583637#comment-13583637
] 

Hoss Man commented on SOLR-4485:
--------------------------------

After watching someone on IRC struggle to understand why "*:* -foo:bar" was giving them unexpected
results (answer: foo wasn't indexed so it was matching all docs) my opinion is that in general,
we should probably make this return a use error in most of the straight forward cases.

I can imagine some hypothetical arguments in favor of things like dismax/edismax allowing
things like qf/pf to contain fields that aren't indexed, and only throw an error if _none_
of them exist, but in general i think any code query parsing code path that complains if a
field doesn't exist should probably complain if the field exists but is not indexed.
                
> Consider making QParsers throw SyntaxError if field being searched is not indexed
> ---------------------------------------------------------------------------------
>
>                 Key: SOLR-4485
>                 URL: https://issues.apache.org/jira/browse/SOLR-4485
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Hoss Man
>
> For historical reasons that i can't even really remember right now most query parsing
in solr don't seem to care if the fields they are asked to search are indexed.  Using hte
4x example schema (where the content field is stored but not indexed), all of these queries
return a 200 status code, and match 0 documents...
> {noformat}
> http://localhost:8983/solr/select?defType=lucene&q=ignored_xx:foo
> http://localhost:8983/solr/select?qf=ignored_xx&defType=edismax&q=foo
> http://localhost:8983/solr/select?qf=ignored_xx&defType=dismax&q=foo
> http://localhost:8983/solr/select?q={!field%20f=ignored_xx}foo
> http://localhost:8983/solr/select?q={!term%20f=ignored_xx}foo
> {noformat}
> I'm opening this issue to gather feedback on whether people think we should treat this
as a bug that should be fixed, or if folks think it's better to leave things as they stand.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

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


Mime
View raw message