EmmyMiao87 opened a new issue #4316: URL: https://github.com/apache/incubator-doris/issues/4316
**Describe the bug** When user create no grouping materialized view on agg table, the job will be executed successfully and the mv keys type is incorrect. **To Reproduce** 1. create table ``` CREATE TABLE `test_sys_materialized_view_2_test_create_agg_mv_tb_agg` ( `k0` boolean NOT NULL COMMENT "", `k1` tinyint(4) NOT NULL COMMENT "", `k2` smallint(6) NOT NULL COMMENT "", `k3` int(11) NOT NULL COMMENT "", `k4` bigint(20) NOT NULL COMMENT "", `k5` largeint(40) NOT NULL COMMENT "", `k6` decimal(9, 3) NOT NULL COMMENT "", `k7` char(5) NOT NULL COMMENT "", `k8` date NOT NULL COMMENT "", `k9` datetime NOT NULL COMMENT "", `k10` varchar(20) NOT NULL COMMENT "", `k11` double MAX NOT NULL COMMENT "", `k12` float SUM NOT NULL COMMENT "", `k13` hll HLL_UNION NOT NULL COMMENT "", `k14` bitmap BITMAP_UNION NOT NULL COMMENT "" ) ENGINE=OLAP AGGREGATE KEY(`k0`, `k1`, `k2`, `k3`, `k4`, `k5`, `k6`, `k7`, `k8`, `k9`, `k10`) COMMENT "OLAP" DISTRIBUTED BY HASH(`k4`, `k5`) BUCKETS 10 PROPERTIES ( "replication_num" = "3", "in_memory" = "false", "storage_format" = "DEFAULT" ); ``` 2. create mv ``` CREATE MATERIALIZED VIEW mv1 AS select k6, k7 from test_sys_materialized_view_2_test_create_agg_mv_tb_agg ``` 3.  **Expected behavior** throw exception when creating mv. error_msg: `The materialized view of aggregation table must has grouping columns` ---------------------------------------------------------------- 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. 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