2020-01-18 02:47:55 +00:00
|
|
|
SELECT id
|
2021-05-15 09:11:13 +00:00
|
|
|
FROM
|
2020-01-18 02:47:55 +00:00
|
|
|
(
|
|
|
|
SELECT 1 AS id
|
|
|
|
UNION ALL
|
|
|
|
SELECT NULL
|
|
|
|
UNION ALL
|
|
|
|
SELECT NULL
|
2020-02-26 13:11:06 +00:00
|
|
|
) js1
|
2020-01-18 02:47:55 +00:00
|
|
|
ALL FULL OUTER JOIN
|
|
|
|
(
|
|
|
|
SELECT 1 AS id
|
|
|
|
UNION ALL
|
|
|
|
SELECT NULL
|
|
|
|
UNION ALL
|
|
|
|
SELECT NULL
|
2020-02-26 13:11:06 +00:00
|
|
|
) js2 USING (id)
|
2020-01-18 02:47:55 +00:00
|
|
|
ORDER BY id;
|
|
|
|
|
|
|
|
SELECT '---';
|
|
|
|
|
|
|
|
SELECT *
|
2021-05-15 09:11:13 +00:00
|
|
|
FROM
|
2020-01-18 02:47:55 +00:00
|
|
|
(
|
|
|
|
SELECT NULL AS x
|
2020-02-26 13:11:06 +00:00
|
|
|
) js1
|
2020-01-18 02:47:55 +00:00
|
|
|
INNER JOIN
|
|
|
|
(
|
|
|
|
SELECT NULL AS x
|
2020-02-26 13:11:06 +00:00
|
|
|
) js2 USING (x);
|
2020-01-18 02:47:55 +00:00
|
|
|
|
|
|
|
SELECT '---';
|
|
|
|
|
|
|
|
SELECT *
|
2021-05-15 09:11:13 +00:00
|
|
|
FROM
|
2020-01-18 02:47:55 +00:00
|
|
|
(
|
|
|
|
SELECT NULL AS x
|
2020-02-26 13:11:06 +00:00
|
|
|
) js1
|
2020-01-18 02:47:55 +00:00
|
|
|
FULL OUTER JOIN
|
|
|
|
(
|
|
|
|
SELECT NULL AS x
|
2020-02-26 13:11:06 +00:00
|
|
|
) js2 USING (x);
|