Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 51b0377

Browse files
committed
avoid xinv* table name conflict with large objects.
1 parent 34fa6c6 commit 51b0377

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

src/backend/commands/vacuum.c

+4-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.34 1997/06/06 03:41:16 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.35 1997/06/07 05:18:47 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -313,9 +313,10 @@ vc_getrels(NameData *VacRelP)
313313
}
314314

315315
/* don't vacuum large objects for now - something breaks when we do */
316-
if ( (strlen(rname) > 4) && rname[0] == 'x' &&
316+
if ( (strlen(rname) > 5) && rname[0] == 'x' &&
317317
rname[1] == 'i' && rname[2] == 'n' &&
318-
(rname[3] == 'v' || rname[3] == 'x'))
318+
(rname[3] == 'v' || rname[3] == 'x') &&
319+
rname[4] >= '0' && rname[4] <= '9')
319320
{
320321
elog (NOTICE, "Rel %.*s: can't vacuum LargeObjects now",
321322
NAMEDATALEN, rname);

src/bin/pg_dump/pg_dump.c

+2-2
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.30 1997/06/05 22:59:45 momjian Exp $
24+
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.31 1997/06/07 05:19:06 momjian Exp $
2525
*
2626
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
2727
*
@@ -1081,7 +1081,7 @@ getTables(int *numTables)
10811081
sprintf(query,
10821082
"SELECT oid, relname, relarch, relkind, relacl from pg_class "
10831083
"where (relkind = 'r' or relkind = 'S') and relname !~ '^pg_' "
1084-
"and relname !~ '^xinv' order by oid;");
1084+
"and relname !~ '^xinv[0-9]' order by oid;");
10851085

10861086
res = PQexec(g_conn, query);
10871087
if (!res ||

0 commit comments

Comments
 (0)