Lif0820 opened a new issue, #32548: URL: https://github.com/apache/doris/issues/32548
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues. ### Description CREATE TABLE test_event_log ( device_id bigint(20) NULL, v1 double NULL, v2 double NULL, time_key int(11) NULL COMMENT 'yyyyMMdd', ) ENGINE=OLAP DUPLICATE KEY(device_id) COMMENT 'OLAP' PARTITION BY RANGE(time_key) ( PARTITION p202401 VALUES [("20240101"), ("20240201")), PARTITION p202402 VALUES [("20240201"), ("20240301")), PARTITION p202403 VALUES [("20240301"), ("20240401")), PARTITION p202404 VALUES [("20240401"), ("20240501"))) DISTRIBUTED BY HASH(device_id) BUCKETS 16 PROPERTIES ( "replication_allocation" = "tag.location.default: 3", "enable_single_replica_compaction" = "false" ); insert into test_event_log VALUES (1, 1, 1, 20240101); insert into test_event_log VALUES (2, 2, 2, 20240201); insert into test_event_log VALUES (3, 3, 2, 20240301); explain select count(*) from test_event_log where time_key = substr('20240301000000', 1, 8) -- can not partition prune -- where time_key = cast('20240301' as bigint) -- can not partition prune -- where time_key = '20240301'; -- ok ### Solution _No response_ ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- 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]
