mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Merge mhansson@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into dl145s.mysql.com:/users/mhansson/mysql/autopush/5.0o-bug24010
This commit is contained in:
@ -434,3 +434,22 @@ Handler_read_prev 0
|
|||||||
Handler_read_rnd 0
|
Handler_read_rnd 0
|
||||||
Handler_read_rnd_next 21
|
Handler_read_rnd_next 21
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
a INT(11),
|
||||||
|
quux decimal( 31, 30 ),
|
||||||
|
UNIQUE KEY bar (a),
|
||||||
|
KEY quux (quux)
|
||||||
|
);
|
||||||
|
INSERT INTO
|
||||||
|
t1 ( a, quux )
|
||||||
|
VALUES
|
||||||
|
( 1, 1 ),
|
||||||
|
( 2, 0.1 );
|
||||||
|
INSERT INTO t1( a )
|
||||||
|
SELECT @newA := 1 + a FROM t1 WHERE quux <= 0.1;
|
||||||
|
SELECT * FROM t1;
|
||||||
|
a quux
|
||||||
|
1 1.000000000000000000000000000000
|
||||||
|
2 0.100000000000000000000000000000
|
||||||
|
3 NULL
|
||||||
|
DROP TABLE t1;
|
||||||
|
@ -342,3 +342,29 @@ UPDATE t1 SET user_id=null WHERE request_id=999999999999999999999999999999;
|
|||||||
show status like '%Handler_read%';
|
show status like '%Handler_read%';
|
||||||
|
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
#
|
||||||
|
# Bug #24010: INSERT INTO ... SELECT fails on unique constraint with data it
|
||||||
|
# doesn't select
|
||||||
|
#
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
|
||||||
|
a INT(11),
|
||||||
|
quux decimal( 31, 30 ),
|
||||||
|
|
||||||
|
UNIQUE KEY bar (a),
|
||||||
|
KEY quux (quux)
|
||||||
|
);
|
||||||
|
|
||||||
|
INSERT INTO
|
||||||
|
t1 ( a, quux )
|
||||||
|
VALUES
|
||||||
|
( 1, 1 ),
|
||||||
|
( 2, 0.1 );
|
||||||
|
|
||||||
|
INSERT INTO t1( a )
|
||||||
|
SELECT @newA := 1 + a FROM t1 WHERE quux <= 0.1;
|
||||||
|
|
||||||
|
SELECT * FROM t1;
|
||||||
|
|
||||||
|
DROP TABLE t1;
|
||||||
|
Reference in New Issue
Block a user