· 8 years ago · Jul 16, 2018, 12:10 PM
1INSERT INTO A (`id`) VALUES (NULL)
2
3Column 'id' cannot be null
4
5INSERT INTO A (`id`) values (0)
6
7drop table if exists A;
8create table A
9(
10id int unsigned not null auto_increment primary key
11)
12engine=innodb;
13
14insert into A (id) values (null),(null);
15
16mysql> select * from A order by id;
17+----+
18| id |
19+----+
20| 1 |
21| 2 |
22+----+
232 rows in set (0.00 sec)
24
25INSERT INTO `A` VALUES ()