For example, the following query:
select deptno, rank() over(partition by empno order by deptno) from emp order by row_number() over(partition by empno order by deptno.
The default null order is nulls last for deptno in calcite. But the null order still is nulls last if we set the parameter "defaultNullCollation" with NullCollation.LOW.