morrySnow commented on code in PR #40768:
URL: https://github.com/apache/doris/pull/40768#discussion_r1796712381


##########
fe/fe-core/src/main/java/org/apache/doris/analysis/Analyzer.java:
##########
@@ -830,17 +830,14 @@ public TableRef resolveTableRef(TableRef tableRef) throws 
AnalysisException {
                 .getDbOrAnalysisException(tableName.getDb());
         TableIf table = 
database.getTableOrAnalysisException(tableName.getTbl());
 
-        if (table.isManagedTable() && (((OlapTable) table).getState() == 
OlapTableState.RESTORE
-                || ((OlapTable) table).getState() == 
OlapTableState.RESTORE_WITH_LOAD)) {
-            Boolean isAnyPartitionRestoring = ((OlapTable) 
table).getPartitions().stream()
-                    .anyMatch(partition -> partition.getState() == 
PartitionState.RESTORE);
-            if (isAnyPartitionRestoring) {
-                // if doing restore with partitions, the status check push 
down to OlapScanNode::computePartitionInfo to
-                // support query that partitions is not restoring.
-            } else {
-                // if doing restore with table, throw exception here
-                
ErrorReport.reportAnalysisException(ErrorCode.ERR_BAD_TABLE_STATE, "RESTORING");
-            }
+        Boolean isAllPartitionRestoring = ((OlapTable) 
table).getPartitions().stream()

Review Comment:
   legacy planner will be remove very soon, so u should impl it in Nereids



-- 
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: commits-unsubscr...@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to