kgyrtkirk commented on code in PR #15195:
URL: https://github.com/apache/druid/pull/15195#discussion_r1365885683
##########
sql/src/main/java/org/apache/druid/sql/calcite/planner/DruidSqlValidator.java:
##########
@@ -39,4 +44,23 @@ protected DruidSqlValidator(
{
super(opTab, catalogReader, typeFactory, validatorConfig);
}
+
+ @Override
+ public void validateCall(SqlCall call, SqlValidatorScope scope)
+ {
+ if (call.getKind() == SqlKind.NULLS_FIRST) {
+ SqlNode op0 = call.getOperandList().get(0);
+ if (op0.getKind() == SqlKind.DESCENDING) {
+ throw InvalidSqlInput.exception("DESCENDING ordering with NULLS FIRST
is not supported!");
Review Comment:
yeah; I guessed there will be some which can't be changed - however at a lot
of callsites we do have an `SqlNode` ; I had in mind to target those
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]