is currently failing to convert to calcite with a ClassCastException, since it doesn't expect the ORDER BY clause to be arbitrarily complex expressions, only RexSlots.
java.lang.ClassCastException: class org.apache.calcite.rex.RexLiteral cannot be cast to class org.apache.calcite.rex.RexSlot (org.apache.calcite.rex.RexLiteral and org.apache.calcite.rex.RexSlot are in unnamed module of loader 'app')
at io.substrait.isthmus.SubstraitRelNodeConverter.toRelFieldCollation(SubstraitRelNodeConverter.java:347)
at io.substrait.isthmus.SubstraitRelNodeConverter.lambda$visit$7(SubstraitRelNodeConverter.java:318)
The substrait for a SQL query like:
is currently failing to convert to calcite with a
ClassCastException
, since it doesn't expect theORDER BY
clause to be arbitrarily complex expressions, onlyRexSlot
s.Full substrait file: class-cast-exception.json