pingcap / pingcap/tidb

Incorrect error message while executing statement

Open
#65,661 2 comments 0 reactions 0 assignees View on GitHub
contribution severity/minor sig/execution type/bug
Dominant language
Go
Stars
40.5k
Forks
6.2k
PR merge metrics
PR metrics pending

Description

## Bug Report

Please answer these questions before submitting your issue. Thanks!

### 1. Minimal reproduce step (Required)
```sql
create table t93(c0 double unsigned , c1 bigint unsigned default 1613304850 , c2 tinyint zerofill auto_increment primary key);
REPLACE INTO t93 VALUES (0.47377245333224627, 930, NULL), (0.282268885336872, 931, 1161682028), (NULL, 932, 127315013), (0.5835544590210913, 933, -1819631713), (0.13816855100299408, 934, -1875759020), (0.282268885336872, 935, -1392333466);
```

### 2. What did you expect to see? (Required)
```sql
mysql> REPLACE INTO t93 VALUES (0.47377245333224627, 930, NULL), (0.282268885336872, 931, 1161682028), (NULL, 932, 127315013), (0.5835544590210913, 933, -1819631713), (0.13816855100299408, 934, -1875759020), (0.282268885336872, 935, -1392333466);
ERROR 1264 (22003): Out of range value for column 'c2' at row 2
```

### 3. What did you see instead (Required)
```sql
mysql> REPLACE INTO t93 VALUES (0.47377245333224627, 930, NULL), (0.282268885336872, 931, 1161682028), (NULL, 932, 127315013), (0.5835544590210913, 933, -1819631713), (0.13816855100299408, 934, -1875759020), (0.282268885336872, 935, -1392333466);
ERROR 1467 (HY000): Failed to read auto-increment value from storage engine
```

### 4. What is your TiDB version? (Required)
8.0.11-TiDB-v9.0.0-beta.1.pre-640-g24903d6b24

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.