[ 
https://issues.apache.org/jira/browse/DRILL-7200?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16876833#comment-16876833
 ] 

ASF GitHub Bot commented on DRILL-7200:
---------------------------------------

arina-ielchiieva commented on pull request #1818: DRILL-7200: Update Calcite to 
1.19.0 / 1.20.0
URL: https://github.com/apache/drill/pull/1818#discussion_r299400307
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/SqlConverter.java
 ##########
 @@ -403,8 +411,20 @@ public RelRoot toRel(final SqlNode validatedNode) {
         new SqlToRelConverter(new Expander(), validator, catalog, cluster, 
DrillConvertletTable.INSTANCE,
             sqlToRelConverterConfig);
 
-    //To avoid unexpected column errors set a value of top to false
-    final RelRoot rel = sqlToRelConverter.convertQuery(validatedNode, false, 
false);
+    RelRoot rel = sqlToRelConverter.convertQuery(validatedNode, false, 
!isInnerQuery || isExpandedView);
+
+    // If extra expressions used in ORDER BY were added to the project list,
+    // add another project to remove them.
+    if ((!isInnerQuery || isExpandedView) && 
rel.rel.getRowType().getFieldCount() - rel.fields.size() > 0) {
+      List<RexNode> exprs = new ArrayList<>();
 
 Review comment:
   Can we use stream?
 
----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> Update Calcite to 1.19.0 / 1.20.0
> ---------------------------------
>
>                 Key: DRILL-7200
>                 URL: https://issues.apache.org/jira/browse/DRILL-7200
>             Project: Apache Drill
>          Issue Type: Task
>    Affects Versions: 1.16.0
>            Reporter: Bohdan Kazydub
>            Assignee: Bohdan Kazydub
>            Priority: Major
>             Fix For: 1.17.0
>
>
> Calcite has released the 1.19.0 version. Upgrade Calcite dependency in Drill 
> to the newest version.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to