RR 插入不影响

来源:互联网 发布:java中的抽象类的作用 编辑:程序博客网 时间:2024/04/27 03:12
| test100 | CREATE TABLE `test100` (  `sn` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增编号',  `phoneNo` int(11) DEFAULT NULL,  `channelType` int(11) DEFAULT NULL COMMENT '通道识别',  `status` tinyint(4) NOT NULL COMMENT '短信转态,1.发送成功,2.发送失败,3.发送异常',  PRIMARY KEY (`sn`),  KEY `test100_idx1` (`phoneNo`)) ENGINE=InnoDB AUTO_INCREMENT=5028 DEFAULT CHARSET=utf8 COMMENT='短信发送成功记录表'                                  |+---------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+1 row in set (0.02 sec)mysql> select * from test100 limit 20;+----+---------+-------------+--------+| sn | phoneNo | channelType | status |+----+---------+-------------+--------+|  1 |       1 |           2 |      1 ||  2 |       2 |           2 |      1 ||  3 |       3 |           2 |      1 ||  4 |       4 |           2 |      1 ||  5 |       5 |           2 |      1 ||  6 |       6 |           2 |      1 ||  7 |       7 |           2 |      1 ||  8 |       8 |           2 |      1 ||  9 |       9 |           2 |      1 || 10 |      10 |           2 |      1 || 11 |      11 |           2 |      1 || 16 |      16 |           2 |      1 || 17 |      17 |           2 |      1 || 18 |      18 |           2 |      1 || 19 |      19 |           2 |      1 || 20 |      20 |           2 |      1 || 21 |      21 |           2 |      1 || 22 |      22 |           2 |      1 || 23 |      23 |           2 |      1 || 24 |      24 |           2 |      1 |+----+---------+-------------+--------+20 rows in set (0.00 sec)Session 1:mysql> select * from test100 limit 20;+----+---------+-------------+--------+| sn | phoneNo | channelType | status |+----+---------+-------------+--------+|  1 |       1 |           2 |      1 ||  2 |       2 |           2 |      1 ||  3 |       3 |           2 |      1 ||  4 |       4 |           2 |      1 ||  5 |       5 |           2 |      1 ||  6 |       6 |           2 |      1 ||  7 |       7 |           2 |      1 ||  8 |       8 |           2 |      1 ||  9 |       9 |           2 |      1 || 10 |      10 |           2 |      1 || 11 |      11 |           2 |      1 || 16 |      16 |           2 |      1 || 17 |      17 |           2 |      1 || 18 |      18 |           2 |      1 || 19 |      19 |           2 |      1 || 20 |      20 |           2 |      1 || 21 |      21 |           2 |      1 || 22 |      22 |           2 |      1 || 23 |      23 |           2 |      1 || 24 |      24 |           2 |      1 |+----+---------+-------------+--------+20 rows in set (0.00 sec)mysql> SELECT @@tx_isolation;+-----------------+| @@tx_isolation  |+-----------------+| REPEATABLE-READ |+-----------------+1 row in set (0.01 sec)mysql> start transaction;Query OK, 0 rows affected (0.00 sec)mysql> insert into test100(phoneNo,channelType,status) values(15,1,1);Query OK, 1 row affected (0.05 sec)Session 2:mysql> use zjzc;Reading table information for completion of table and column namesYou can turn off this feature to get a quicker startup with -ADatabase changedmysql>  insert into test100(phoneNo,channelType,status) values(15,1,1);Query OK, 1 row affected (0.01 sec)mysql>  insert into test100(phoneNo,channelType,status) values(14,1,1);Query OK, 1 row affected (0.01 sec)mysql>  insert into test100(phoneNo,channelType,status) values(16,1,1);Query OK, 1 row affected (0.00 sec)

0 0