github-actions[bot] commented on code in PR #69488:
URL: https://github.com/apache/doris/pull/69488#discussion_r4409014234


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rules/RewriteDefaultExpression.java:
##########
@@ -18,7 +18,10 @@
 package org.apache.doris.nereids.rules.expression.rules;
 
 import org.apache.doris.catalog.Column;
+import org.apache.doris.catalog.TableIf;
+import org.apache.doris.datasource.plugin.PluginDrivenExternalTable;
 import org.apache.doris.nereids.CascadesContext;
+import org.apache.doris.nereids.StatementContext;
 import org.apache.doris.nereids.analyzer.UnboundFunction;

Review Comment:
   [P1] Do not substitute Iceberg write-defaults in DELETE predicates
   
   `RowLevelDmlCommand.run` pins the connector writer schema for DELETE as well 
as UPDATE/MERGE. Consequently, on an Iceberg table whose `c` write-default is 
`35`, `DELETE FROM t WHERE c = DEFAULT(c)` reaches this new branch, replaces 
`DEFAULT(c)` with `35`, and deletes every row with `c = 35`. The PR documents 
writer-default predicate resolution for INSERT/UPDATE/MERGE, while DELETE has 
no row-value default context and previously saw the read schema (which carries 
no Iceberg write-default). Restrict this substitution to the documented 
operations or reject `DEFAULT` in DELETE, and add a regression covering the 
predicate.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to