tuichenchuxin commented on a change in pull request #14307:
URL: https://github.com/apache/shardingsphere/pull/14307#discussion_r779242879



##########
File path: 
shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/constant/SubqueryType.java
##########
@@ -22,5 +22,5 @@
  */
 public enum SubqueryType {
     
-    PROJECTION_SUBQUERY, TABLE_SUBQUERY, PREDICATE_SUBQUERY, 
INSERT_SELECT_SUBQUERY;
+    PROJECTION_SUBQUERY, TABLE_SUBQUERY, PREDICATE_SUBQUERY, 
INSERT_SELECT_SUBQUERY, EXISTS_SUBQUERY;

Review comment:
       Why we need this type?
   I thought these types is to determine the place where subquery in.
   And different place may need to handle differently.

##########
File path: 
shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/common/util/SubqueryExtractUtil.java
##########
@@ -128,6 +128,12 @@
             
result.addAll(getSubquerySegmentsFromExpression(((BetweenExpression) 
expressionSegment).getBetweenExpr()));
             
result.addAll(getSubquerySegmentsFromExpression(((BetweenExpression) 
expressionSegment).getAndExpr()));
         }
+        if (expressionSegment instanceof ExistsSubqueryExpression) {

Review comment:
       Line 108 need to delete.




-- 
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]


Reply via email to