You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[bug](delete) fix delete random distributed tbl (#37985)
## Proposed changes
Bug description:
In PR #33630, Doris supports auto
aggregation for random distributed table, but it not only effects query
statements, so if we delete from a random distributed table, will get an
error because of unexpectedly rewriting.
```
CREATE TABLE `test_tbl` (
`k` INT NULL,
`v` BIGINT SUM NULL
) ENGINE=OLAP
AGGREGATE KEY(`k`)
DISTRIBUTED BY RANDOM BUCKETS AUTO;
mysql > delete from test_tbl where k=1;
ERROR 1105 (HY000): errCode = 2, detailMessage = Where clause only supports compound predicate, binary predicate, is_null predicate or in predicate.
```
fix:
Check whether it is a query statement before rewriting.
0 commit comments