Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit37ce95c

Browse files
committed
Update FAQ.
1 parent9c77f4e commit37ce95c

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

‎doc/FAQ

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@
102102
Why?
103103
4.22) How do I create a column that will default to the current time?
104104
4.23) Why are my subqueries using IN so slow?
105+
4.24) How do I do an outer join?
105106

106107
Extending PostgreSQL
107108

@@ -992,6 +993,21 @@ BYTEA bytea variable-length array of bytes
992993
WHERE EXISTS (SELECT col2 FROM TAB2 WHERE col1 = col2)
993994

994995
We hope to fix this limitation in a future release.
996+
997+
4.24) How do I do an outer join?
998+
999+
PostgreSQL does not support outer joins in the current release. They
1000+
can be simulated using UNION and NOT IN. For example, when joining
1001+
tab1 and tab2, the following query does an outer join of the two
1002+
tables:
1003+
SELECT tab1.col1, tab2.col2
1004+
FROM tab1, tab2
1005+
WHERE tab1.col1 = tab2.col1
1006+
UNION ALL
1007+
SELECT tab1.col1, NULL
1008+
FROM tab1
1009+
WHERE tab1.col1 NOT IN (SELECT tab2.col1 FROM tab2)
1010+
ORDER BY tab1.col1
9951011
_________________________________________________________________
9961012

9971013
Extending PostgreSQL

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp