We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL CREATE TABLE t1 (e enum('a','b') NOT NULL PRIMARY KEY); Query OK, 0 rows affected (0.1761 sec) 5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL SET sql_mode=''; Query OK, 0 rows affected (0.0008 sec) 5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL INSERT INTO t1 VALUES('foo'); Query OK, 1 row affected, 1 warning (0.0569 sec) Warning (code 1265): Data truncated for column '%s' at row %d
Warning (code 1265): Data truncated for column 'e' at row 1
Warning (code 1265): Data truncated for column '%s' at row %d
5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL SELECT tidb_version()\G *************************** 1. row *************************** tidb_version(): Release Version: v5.2.1 Edition: Community Git Commit Hash: cd8fb24c5f7ebd9d479ed228bb41848bd5e97445 Git Branch: heads/refs/tags/v5.2.1 UTC Build Time: 2021-09-08 02:32:56 GoVersion: go1.16.4 Race Enabled: false TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306 Check Table Before Drop: false 1 row in set (0.0012 sec)
The error works fine:
5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL set sql_mode='strict_all_tables'; Query OK, 0 rows affected (0.0008 sec) 5.7.25-TiDB-v5.2.1 127.0.0.1:4000 test SQL INSERT INTO t1 VALUES('foo'); ERROR: 1265 (01000): Data truncated for column 'e' at row 1
#27503 might be related
The text was updated successfully, but these errors were encountered:
This is fixed in master. Probably fixed by #47267
sql> CREATE TABLE t1 (e enum('a','b') NOT NULL PRIMARY KEY); Query OK, 0 rows affected (0.0177 sec) sql> SET sql_mode=''; Query OK, 0 rows affected (0.0007 sec) sql> INSERT INTO t1 VALUES('foo'); Query OK, 1 row affected, 1 warning (0.0033 sec) Warning (code 1265): Data truncated for column 'e' at row 1 sql> SELECT TIDB_VERSION()\G *************************** 1. row *************************** TIDB_VERSION(): Release Version: v7.5.0-alpha-6-g2992c1cc98 Edition: Community Git Commit Hash: 2992c1cc98bfee3b62a27b9913a308e1cfa96667 Git Branch: master UTC Build Time: 2023-09-28 09:13:58 GoVersion: go1.21.0 Race Enabled: false Check Table Before Drop: false Store: unistore 1 row in set (0.0009 sec)
Sorry, something went wrong.
No branches or pull requests
Bug Report
1. Minimal reproduce step (Required)
2. What did you expect to see? (Required)
3. What did you see instead (Required)
4. What is your TiDB version? (Required)
Other info
The error works fine:
#27503 might be related
The text was updated successfully, but these errors were encountered: