lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan Høydahl (JIRA) <>
Subject [jira] [Commented] (SOLR-2441) Requesting invalid field names should return an error
Date Fri, 25 Mar 2011 12:17:06 GMT


Jan Høydahl commented on SOLR-2441:

I tend to like the flexibility of Solr wrt. fields and schema.
Even if you have a schema, Solr does not try to enforce it query-time, you kind of get the
same transparent behavior as with Lucene, that if the docs you query contain the fields requested,
you get them, if not you don't. You may modify your schema without re-indexing your content
and still be able to retrieve fields.

And what if I choose to shard across two Solr's with different scemas - because I know they
share the "id", "title", "body" fields. Could be a webcrawl core and a fileserver core. I
may want to query on the title&body only, but ask for fl=id,title,url,meta_keywords,file_path
and choose to render my web results using url and meta_keywords but my fileserver docs with

Have you considered dynamic fields?

Based on this I think this solution is not a good idea, at least it should be configurable
and by default off.

> Requesting invalid field names should return an error
> -----------------------------------------------------
>                 Key: SOLR-2441
>                 URL:
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Ryan McKinley
>            Assignee: Ryan McKinley
>             Fix For: 4.0
>         Attachments: SOLR-2441-invalid-fl-error.patch, SOLR-2441-invalid-fl-error.patch
> If  you send a request for *fl=foofoofoo* and that field does not exist, solr just returns
empty documents:
> {code}
> <result name="response" numFound="17" start="0">
>   <doc></doc>
>   <doc></doc>
>   <doc></doc>
> </result>
> {code}
> This seems like an error, not something we should support.  (I think requesting an invalid
field name should also be an error, but that is another issue)
> The distributed tests check if this is supported -- I don't think they should

This message is automatically generated by JIRA.
For more information on JIRA, see:

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

View raw message