[
https://issues.apache.org/jira/browse/LUCENE-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hoss Man updated LUCENE-4218:
-----------------------------
Fix Version/s: 4.0
4.0.0-APHA docs for Document.get say (emphasis mine)...
bq. Returns the string value of the field with the given name if any exist in
this document, or null. If multiple fields exist with this name, this method
returns the first value added. If only binary fields with this name exist,
returns null. *For IntField, LongField, FloatField and DoubleField it returns
the string value of the number.* If you want the actual numeric field instance
back, use getField(java.lang.String).
...not sure if the problem is the docs, or if the method is broken, but either
way we should fix
> contrary to documentation Document.get(field) on numeric field returns null
> ---------------------------------------------------------------------------
>
> Key: LUCENE-4218
> URL: https://issues.apache.org/jira/browse/LUCENE-4218
> Project: Lucene - Core
> Issue Type: Bug
> Components: core/search
> Affects Versions: 4.0-ALPHA
> Environment: Darwin e4-ce-8f-0f-c2-b0.dummy.porta.siemens.net 10.8.0
> Darwin Kernel Version 10.8.0: Tue Jun 7 16:32:41 PDT 2011;
> root:xnu-1504.15.3~1/RELEASE_X86_64 x86_64
> Reporter: Jamie
> Priority: Critical
> Labels: Document
> Fix For: 4.0
>
>
> A call to Numeric num = indexableField.numericValue() comes up with a correct
> value, whereas Document.get(field) yields null.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]