HappenLee opened a new issue #5186:
URL: https://github.com/apache/incubator-doris/issues/5186


   **Is your feature request related to a problem? Please describe.**
   Now,we always use `show create table` to create a two table is same. But 
when we create partition table, there may be some problem.
   
   1. create table 
   ```
   CREATE TABLE `test2` (
     `k1` date NOT NULL COMMENT ""
   ) ENGINE=OLAP
   AGGREGATE KEY(`k1`)
   COMMENT "OLAP"
   PARTITION BY RANGE(`k1`)
   (PARTITION p1 values less than ("20201202"),
   PARTITION p2 values less than MAXVALUE)
   DISTRIBUTED BY HASH(`k1`) BUCKETS 5
   PROPERTIES (
   "replication_num" = "1",
   "in_memory" = "false",
   "storage_format" = "V2"
   );
   ```
   
   2. show create table of `test2`
   ```
   CREATE TABLE `test2` (
     `k1` date NOT NULL COMMENT ""
   ) ENGINE=OLAP
   AGGREGATE KEY(`k1`)
   COMMENT "OLAP"
   PARTITION BY RANGE(`k1`)
   (PARTITION p1 VALUES [('0000-01-01'), ('2020-12-02')),
   PARTITION p2 VALUES [('2020-12-02'), (MAXVALUE)))
   DISTRIBUTED BY HASH(`k1`) BUCKETS 5
   PROPERTIES (
   "replication_num" = "1",
   "in_memory" = "false",
   "storage_format" = "V2"
   );
   ```
   
   3. we need create same table use code show 2, buf failed
   ```
   CREATE TABLE `test3` (   `k1` date NOT NULL COMMENT "" ) ENGINE=OLAP 
AGGREGATE KEY(`k1`) COMMENT "OLAP" PARTITION BY RANGE(`k1`) (PARTITION p1 
VALUES [('0000-01-01'), ('2020-12-02')), PARTITION p2 VALUES [('2020-12-02'), 
(MAXVALUE))) DISTRIBUTED BY HASH(`k1`) BUCKETS 5 PROPERTIES ( "replication_num" 
= "1", "in_memory" = "false", "storage_format" = "V2" );
   ERROR 1064 (HY000): errCode = 2, detailMessage = Not support MAXVALUE in 
partition range values.
   ```
   
   it really make me exasperation sometime.
   
   **Describe the solution you'd like**
   
   support MAXVALUE in partition range values.
   
   


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

Reply via email to