Vincenzo, As I read the source code; SchemaField.java
/** * Sanity checks that the properties of this field type are plausible * for a field that may be used to get a FieldCacheSource, throwing * an appropriate exception (including the field name) if it is not. * FieldType subclasses can choose to call this method in their * getValueSource implementation * @see FieldType#getValueSource */ public void checkFieldCacheSource() throws SolrException { if ( multiValued() ) { throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, "can not use FieldCache on multivalued field: " + getName()); } if (! hasDocValues() ) { if ( ! ( indexed() && null != this.type.getUninversionType(this) ) ) { throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, "can not use FieldCache on a field w/o docValues unless it is indexed and supports Uninversion: " + getName()); } } } Seems like FieldCache are not allowed to un-invert values for multi-valued fields. I can suspect the reason, multiple values will eat up more memory? Not sure, someone else can weigh in. Amrit Sarkar Search Engineer Lucidworks, Inc. 415-589-9269 www.lucidworks.com Twitter http://twitter.com/lucidworks LinkedIn: https://www.linkedin.com/in/sarkaramrit2 Medium: https://medium.com/@sarkaramrit2 On Mon, Feb 26, 2018 at 7:37 PM, Vincenzo D'Amore <v.dam...@gmail.com> wrote: > Hi, > > while trying to run a group query on a multivalue field I received this > error: > > can not use FieldCache on multivalued field: > > <?xml version="1.0" encoding="UTF-8"?> > <response> > > <lst name="responseHeader"> > <bool name="zkConnected">true</bool> > <int name="status">400</int> > <int name="QTime">4</int> > </lst> > <lst name="error"> > <lst name="metadata"> > <str name="error-class">org.apache.solr.common.SolrException</str> > <str name="root-error-class">org.apache.solr.common. > SolrException</str> > </lst> > <str name="msg">can not use FieldCache on multivalued field: > categoryLevels</str> > <int name="code">400</int> > </lst> > </response> > > I don't understand why this is happening. > > Do you know any way to work around this problem? > > Thanks in advance, > Vincenzo > > -- > Vincenzo D'Amore >