Hi Alex, You need to use a BinaryDocValuesField so that the field is indexed with doc values.
`Field` is not going to work because it only indexes the data while index sorting requires doc values. On Fri, Oct 15, 2021 at 6:40 PM Alex K <aklib...@gmail.com> wrote: > Hi all, > > Could someone point me to an example of using the > IndexWriterConfig.setIndexSort for a field containing binary values? > > To be specific, the fields are constructed using the Field(String name, > byte[] value, IndexableFieldType type) constructor, and I'd like to try > using the java.util.Arrays.compareUnsigned method to sort the fields. > > Thanks, > Alex > -- Adrien