phoenix-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] comnetwork commented on a change in pull request #431: PHOENIX-5105
Date Wed, 23 Jan 2019 02:16:45 GMT
comnetwork commented on a change in pull request #431: PHOENIX-5105
URL: https://github.com/apache/phoenix/pull/431#discussion_r250034819
 
 

 ##########
 File path: phoenix-core/src/main/java/org/apache/phoenix/compile/SubselectRewriter.java
 ##########
 @@ -70,12 +69,126 @@ public static boolean isPostFilterConvertible(SelectStatement statement)
throws
         return statement.getLimit() == null && (!statement.isAggregate() || !statement.getGroupBy().isEmpty());
       
     }
     
-    public static SelectStatement applyOrderBy(SelectStatement statement, List<OrderByNode>
orderBy, String subqueryAlias,TableNode tableNode) throws SQLException {
-        if (orderBy == null)
-            return statement;
-        
-        return new SubselectRewriter(null, statement.getSelect(), subqueryAlias).applyOrderBy(statement,
orderBy, tableNode);
-    }
+    /**
+     * <pre>
+     * only append orderByNodes and postFilters, the optimization is left to {@link #flatten(SelectStatement,
SelectStatement)}.
+     * an example is rewrite
+     * SELECT  REVERSE(LOC_ID),"supplier_id",NAME FROM SUPPLIERTABLE  LIMIT 5
 
 Review comment:
   Sorry, in above comments I did not include the "orderByNodes " and "postFilterParseNodes"
parameters,  I would supplement them.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message