Details
-
Bug
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Fixed
-
N/A
-
None
Description
create or replace table t (a int); |
insert into t values (1,2),(3); |
|
get diagnostics condition 1 @n= row_number, @m= message_text;
|
select @n, @m; |
bb-10.7-row_number cb9002bee |
MariaDB [test]> select @n, @m; |
+------+-------------------------------------------------+ |
| @n | @m |
|
+------+-------------------------------------------------+ |
| 0 | Column count doesn't match value count at row 1 | |
+------+-------------------------------------------------+ |
1 row in set (0.001 sec) |
If, however, the error occurs on the 2nd or further rows, ROW_NUMBER is set all right:
MariaDB [test]> insert into t values (1),(2,3);
|
ERROR 1136 (21S01): Column count doesn't match value count at row 2
|
MariaDB [test]> get diagnostics condition 1 @n= row_number, @m= message_text;
|
Query OK, 0 rows affected (0.000 sec)
|
|
MariaDB [test]> select @n, @m;
|
+------+-------------------------------------------------+
|
| @n | @m |
|
+------+-------------------------------------------------+
|
| 2 | Column count doesn't match value count at row 2 |
|
+------+-------------------------------------------------+
|
1 row in set (0.001 sec)
|
Attachments
Issue Links
- is caused by
-
MDEV-10075 Provide index of error causing error in array INSERT
- Closed