twalthr commented on code in PR #24552:
URL: https://github.com/apache/flink/pull/24552#discussion_r1535390991


##########
flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/planner/calcite/PreValidateReWriter.scala:
##########
@@ -234,13 +234,23 @@ object PreValidateReWriter {
 
     call.getKind match {
       case SqlKind.SELECT =>
+        if (
+          targetPosition
+            .size() != 0 && call.asInstanceOf[SqlSelect].getSelectList.size() 
!= targetPosition

Review Comment:
   to improve code readability:
   - you can store `call.asInstanceOf[SqlSelect]` in a local var because its 
needed again below
   - also `targetPosition.isEmpty` is shorter
   
   This should make the if more readable and fit into one line



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to