2017-04-06 21:09:39 +00:00
|
|
|
SET join_use_nulls = 0;
|
2019-08-08 14:20:25 +00:00
|
|
|
SET any_join_distinct_right_table_keys = 1;
|
2019-09-02 12:53:31 +00:00
|
|
|
SET joined_subquery_requires_alias = 0;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY INNER JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY LEFT JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY RIGHT JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY FULL JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
SET join_use_nulls = 1;
|
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY INNER JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY LEFT JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY RIGHT JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|
2017-04-06 21:09:39 +00:00
|
|
|
|
|
|
|
SELECT k, a, b
|
|
|
|
FROM
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS a FROM system.numbers LIMIT 10
|
|
|
|
)
|
|
|
|
ANY FULL JOIN
|
|
|
|
(
|
|
|
|
SELECT number AS k, toString(number) AS b FROM system.numbers LIMIT 5, 10
|
2017-04-06 21:44:52 +00:00
|
|
|
) USING (k) ORDER BY k;
|