linlin994395 opened a new issue, #22113: URL: https://github.com/apache/doris/issues/22113
### Discussed in https://github.com/apache/doris/discussions/22112 <div type='discussions-op-text'> <sup>Originally posted by **linlin994395** July 22, 2023</sup> **1. 建表语句** create table studio_xxx.xxx_dim_server ( `server` int COMMENT '服务器', `pt_dt` date min NOT NULL COMMENT '开服日期' ) ENGINE=OLAP AGGREGATE KEY(`server`) COMMENT 'OLAP' DISTRIBUTED BY HASH(`server`) BUCKETS 1 PROPERTIES ( "replication_num" = "1" ); **2. 初始化插入语句** INSERT INTO studio_xxx.xxx_dim_server select replace(jsonb_extract(data, '$.server'), '"', ""), min(pt_dt) pt_dt from studio_xxx.xxx_ods_total where event_name in ('LogReg', 'LogLogin', 'LogPay') group by replace(jsonb_extract(data, '$.server'), '"', "") 初始化插入后结果如下  **3. ETL语句 每10分钟执行一次** INSERT INTO studio_xxx.xxx_dim_server select replace(jsonb_extract(data, '$.server'), '"', "") server, min(pt_dt) pt_dt from studio_xxx.xxx_ods_total where pt_dt >= '{start_time}' and pt_dt <= '{end_time}' and event_name in ('LogReg', 'LogLogin', 'LogPay') group by replace(jsonb_extract(data, '$.server'), '"', "") **4. 过一段时间 select结果与预期不符(原有2服,3服数据丢失,1服数据pt_dt发生非预期改变)**  **分析:** 1. 怀疑是多副本原因,每次查询到不同的BE节点,BE节点间同步不及时。但设置为单副本,问题依旧,故排除 2. 怀疑AGGREGATE模型在min,replace等聚合方式下,聚合有问题,求解决 </div> -- 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]
