On 11/12/2013 2:37 AM, giovanni.bricc...@banzai.it wrote: > I'm getting some errors reading boolean filelds, can you give me any > suggestions? in this example I only have four "false" fields: > leasing=false, FiltroNovita=false, FiltroFreeShipping=false, Outlet=false. > > this is the stack trace (solr 4.2.1) > > java.lang.NumberFormatException: For input string: "false" > at > java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) > > at java.lang.Integer.parseInt(Integer.java:492) > at java.lang.Integer.valueOf(Integer.java:582) > at org.apache.solr.schema.IntField.toObject(IntField.java:89) > at org.apache.solr.schema.IntField.toObject(IntField.java:43) > at > org.apache.solr.response.BinaryResponseWriter$Resolver.getValue(BinaryResponseWriter.java:223)
Solr stores boolean values internally as a number - 0 or 1. That gets changed to true/false when displaying search results. It sounds like what you have here is quite possibly an index which originally had text fields with the literal string "true" or "false", and you've changed your schema so these fields are now boolean. When you change your schema, you have to reindex. http://wiki.apache.org/solr/HowToReindex Thanks, Shawn