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

Erick Erickson commented on SOLR-10707:
---------------------------------------

Yeah, all the data is here but it's scattered so I'll condense it.

I have these fields in my schema:

<field indexed="true" name="facet_i" stored="false" type="tlong" 
docValues="false" />
<field indexed="false" name="facet_d" stored="false" type="tlong" 
docValues="true"/>
and
<dynamicField name="*_pi" type="pint" indexed="true" stored="true"/>
<dynamicField name="*_pd" type="pdouble" indexed="true" stored="true"/>

Now when I add a doc like this:
doc.addField("id", UUID.randomUUID().toString());
doc.addField("facet_i", 6850281131226296000L);
doc.addField("facet_d", 6850281131226296000L);

I get these fields returned in the doc on a q=*:*&fl=*:

facet_pi: -28447040,
facet_pd: 6850281131226296000,
version: 1567746273059012600,
facet_d: 6850281131226296000

(there's no facet_i returned since my definition has stored="false" set. 
facet_d is being returned since it's DocValues and doesn't need to be stored).

There's no reason I should have a "facet_pi" or a "facet_pd" defined in this 
document, I'm guessing that they were generated from facet_i and facet_d by 
inappropriate matching in the dynamic field definition. By "rule" I meant that 
IIUC any field name in the document that exactly matches a field in the schema 
should _not_ match any dynamic field.


> Dynamic point fields incorrectly being matched
> ----------------------------------------------
>
>                 Key: SOLR-10707
>                 URL: https://issues.apache.org/jira/browse/SOLR-10707
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>    Affects Versions: master (7.0), 6.7
>            Reporter: Erick Erickson
>
> Didn't see this on 6x, but didn't look specifically.
> Indexing a doc with just a single field like this:
> doc.addField("id", UUID.randomUUID().toString());
> doc.addField("facet_i", 6850281131226296000L);
> doc.addField("facet_d", 6850281131226296000L);
> where "facet_i" is defined as:
>   <field indexed="true" name="facet_i" stored="false" type="tlong" 
> docValues="false" />
> and "facet_d" is defined as:
>   <field indexed="false" name="facet_d" stored="false" type="tlong" 
> docValues="true"/>
> Results in the document being returned as:
> facet_pi: -28447040,
> facet_pd: 6850281131226296000,
> _version_: 1567746273059012600,
> facet_d: 6850281131226296000



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to