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

Commit58d8584

Browse files
committed
pg_dump failed on any database containing large objects,
because it ignored the LOs themselves but failed to ignore the indexeson the LOs. How long has this been broken??
1 parentf463c44 commit58d8584

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

‎src/bin/pg_dump/pg_dump.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
*
2222
*
2323
* IDENTIFICATION
24-
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.114 1999/05/29 10:25:31 vadim Exp $
24+
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.115 1999/06/03 04:01:16 tgl Exp $
2525
*
2626
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
2727
*
@@ -1419,7 +1419,9 @@ getTables(int *numTables, FuncInfo *finfo, int numFuncs)
14191419
* ordering by oid is important so that we always process the parent
14201420
* tables before the child tables when traversing the tblinfo*
14211421
*
1422-
* we ignore tables that start with xinv
1422+
* we ignore tables that are not type 'r' (ordinary relation)
1423+
* or 'S' (sequence) --- in particular, Large Object relations
1424+
* (type 'l') are ignored.
14231425
*/
14241426

14251427
sprintf(query,
@@ -1918,7 +1920,7 @@ getIndices(int *numIndices)
19181920
* find all the user-defined indices. We do not handle partial
19191921
* indices.
19201922
*
1921-
*skip 'xinx*' - indices on inversion objects
1923+
*Notice we skip indices on inversion objects (relkind 'l')
19221924
*
19231925
* this is a 4-way join !!
19241926
*/
@@ -1930,7 +1932,7 @@ getIndices(int *numIndices)
19301932
"from pg_index i, pg_class t1, pg_class t2, pg_am a "
19311933
"where t1.oid = i.indexrelid and t2.oid = i.indrelid "
19321934
"and t1.relam = a.oid and i.indexrelid > '%u'::oid "
1933-
"and t2.relname !~ '^pg_' andt1.relkind != 'l'",
1935+
"and t2.relname !~ '^pg_' andt2.relkind != 'l'",
19341936
g_last_builtin_oid);
19351937

19361938
res=PQexec(g_conn,query);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp