mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
WL#2486 - natural and using join according to SQL:2003
* Provide backwards compatibility extension to name resolution of coalesced columns. The patch allows such columns to be qualified with a table (and db) name, as it is in 4.1. Based on a patch from Monty. * Adjusted tests accordingly to test both backwards compatible name resolution of qualified columns, and ANSI-style resolution of non-qualified columns. For this, each affected test has two versions - one with qualified columns, and one without.
This commit is contained in:
@@ -1153,13 +1153,13 @@ a b a1 b
|
||||
4 2 1 2
|
||||
4 2 2 2
|
||||
5 3 NULL NULL
|
||||
SELECT *
|
||||
SELECT t2.a,t2.b,t3.a1,t3.b
|
||||
FROM t2 NATURAL LEFT JOIN t3
|
||||
WHERE t2.a = 4 OR (t2.a > 4 AND t3.a1 IS NULL);
|
||||
b a c a1 c1
|
||||
2 4 0 1 0
|
||||
2 4 0 2 0
|
||||
3 5 0 NULL NULL
|
||||
a b a1 b
|
||||
4 2 1 2
|
||||
4 2 2 2
|
||||
5 3 NULL NULL
|
||||
DROP TABLE t0,t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
CREATE TABLE t1 (a int);
|
||||
CREATE TABLE t2 (a int);
|
||||
|
||||
Reference in New Issue
Block a user