matrixone
matrixone copied to clipboard
[Feature Request]: text data type
Is there an existing issue for the same feature request?
- [X] I have checked the existing issues.
Is your feature request related to a problem?
Text is a common data type.
Describe the feature you'd like
MO supports a single TEXT data type instead of tinytext, mediumtext, text, longtext of MySQL 8.0. It should cover the ranges of these four data types.
Describe implementation you've considered
No response
Documentation, Adoption, Use Case, Migration Strategy
No response
Additional information
No response
This data type will follow these rules:
- The max length is 10485760(1GB). Error will be notified when out of range.
- DEFAULT in DDL and INDEX ON are not supported.
- All existing data types can be converted into text, including bigint/int/smallint/tinyint, float/double, char/varchar, decimal, date, datetime, timestamp and bool.
- Text can be castable to char/varchar,bigint/int/smallint/tinyint, float/double, char/varchar, date, datetime, timestamp and bool. When the length of text is longer than other types, errors will be notified.
- Text can be coercible to char/varchar,bigint/int/smallint/tinyint, float/double, char/varchar, date, timestamp and bool. When the length of text is longer than other types, errors will be notified.
- All functions of char and varchar need support TEXT data type as well.
- Other behavior of text is the same as varchar, including order by, group by, subquery and join.
By following mysql, pg and oracle, there are some adjustment for char, varchar and text:
- The max size of char, varchar and text is 1GB.
- The function which text involved will convert text implicitly to varchar.
we already support full feature for type text in pr #4168
Can we recognize longtext, mediumtext and tinytext with a current MySQL sql statement? @bbbearxyz
Can we recognize longtext, mediumtext and tinytext with a current MySQL sql statement? @bbbearxyz
no, we just use text type
test done,bvt case done