mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Merge bk-internal.mysql.com:/data0/bk/mysql-5.0
into bk-internal.mysql.com:/data0/bk/mysql-5.0-kt
This commit is contained in:
@ -276,7 +276,7 @@ select * from t1;
|
||||
N M
|
||||
3 0
|
||||
delete P1.*,p2.* from `t1` AS P1 INNER JOIN (SELECT N FROM `t1` GROUP BY N HAVING Count(M) > 1) AS p2 ON P1.N = p2.N;
|
||||
ERROR HY000: The target table p2 of the DELETE is not updatable
|
||||
ERROR 42S02: Unknown table 'p2' in MULTI DELETE
|
||||
delete P1.* from `t1` AS P1 INNER JOIN (SELECT aaa FROM `t1` GROUP BY N HAVING Count(M) > 1) AS P2 ON P1.N = P2.N;
|
||||
ERROR 42S22: Unknown column 'aaa' in 'field list'
|
||||
drop table t1;
|
||||
|
@ -5057,4 +5057,19 @@ concat('data was: /', var1, '/')
|
||||
data was: /1/
|
||||
drop table t3|
|
||||
drop procedure bug15217|
|
||||
drop table if exists t3|
|
||||
drop database if exists mysqltest1|
|
||||
create table t3 (a int)|
|
||||
insert into t3 (a) values (1), (2)|
|
||||
create database mysqltest1|
|
||||
use mysqltest1|
|
||||
drop database mysqltest1|
|
||||
select database()|
|
||||
database()
|
||||
NULL
|
||||
select * from (select 1 as a) as t1 natural join (select * from test.t3) as t2|
|
||||
a
|
||||
1
|
||||
use test|
|
||||
drop table t3|
|
||||
drop table t1,t2;
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -157,7 +157,7 @@ UPDATE `t1` AS P1 INNER JOIN (SELECT aaaa FROM `t1` GROUP BY N HAVING Count(M) >
|
||||
delete P1.* from `t1` AS P1 INNER JOIN (SELECT N FROM `t1` GROUP BY N HAVING Count(M) > 1) AS P2 ON P1.N = P2.N;
|
||||
select * from t1;
|
||||
--replace_result P2 p2
|
||||
--error 1288
|
||||
--error ER_UNKNOWN_TABLE
|
||||
delete P1.*,P2.* from `t1` AS P1 INNER JOIN (SELECT N FROM `t1` GROUP BY N HAVING Count(M) > 1) AS P2 ON P1.N = P2.N;
|
||||
-- error 1054
|
||||
delete P1.* from `t1` AS P1 INNER JOIN (SELECT aaa FROM `t1` GROUP BY N HAVING Count(M) > 1) AS P2 ON P1.N = P2.N;
|
||||
|
@ -5962,6 +5962,31 @@ call bug15217()|
|
||||
drop table t3|
|
||||
drop procedure bug15217|
|
||||
|
||||
#
|
||||
# Bug#21002 "Derived table not selecting from a "real" table fails in JOINs"
|
||||
#
|
||||
# A regression caused by the fix for Bug#18444: for derived tables we should
|
||||
# set an empty string as the current database. They do not belong to any
|
||||
# database and must be usable even if there is no database
|
||||
# selected.
|
||||
--disable_warnings
|
||||
drop table if exists t3|
|
||||
drop database if exists mysqltest1|
|
||||
--enable_warnings
|
||||
create table t3 (a int)|
|
||||
insert into t3 (a) values (1), (2)|
|
||||
|
||||
create database mysqltest1|
|
||||
use mysqltest1|
|
||||
drop database mysqltest1|
|
||||
|
||||
# No current database
|
||||
select database()|
|
||||
|
||||
select * from (select 1 as a) as t1 natural join (select * from test.t3) as t2|
|
||||
use test|
|
||||
drop table t3|
|
||||
|
||||
#
|
||||
# BUG#NNNN: New bug synopsis
|
||||
#
|
||||
|
Reference in New Issue
Block a user