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

Commit3799581

Browse files
committed
Update pg_dump to support dumping operator families.
1 parent867c133 commit3799581

File tree

5 files changed

+411
-15
lines changed

5 files changed

+411
-15
lines changed

‎src/bin/pg_dump/common.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*
1212
*
1313
* IDENTIFICATION
14-
* $PostgreSQL: pgsql/src/bin/pg_dump/common.c,v 1.95 2007/01/05 22:19:48 momjian Exp $
14+
* $PostgreSQL: pgsql/src/bin/pg_dump/common.c,v 1.96 2007/01/23 17:54:50 tgl Exp $
1515
*
1616
*-------------------------------------------------------------------------
1717
*/
@@ -77,6 +77,7 @@ getSchemaData(int *numTablesPtr)
7777
ProcLangInfo*proclanginfo;
7878
CastInfo*castinfo;
7979
OpclassInfo*opcinfo;
80+
OpfamilyInfo*opfinfo;
8081
ConvInfo*convinfo;
8182
intnumNamespaces;
8283
intnumAggregates;
@@ -85,6 +86,7 @@ getSchemaData(int *numTablesPtr)
8586
intnumProcLangs;
8687
intnumCasts;
8788
intnumOpclasses;
89+
intnumOpfamilies;
8890
intnumConversions;
8991

9092
if (g_verbose)
@@ -117,6 +119,10 @@ getSchemaData(int *numTablesPtr)
117119
write_msg(NULL,"reading user-defined operator classes\n");
118120
opcinfo=getOpclasses(&numOpclasses);
119121

122+
if (g_verbose)
123+
write_msg(NULL,"reading user-defined operator families\n");
124+
opfinfo=getOpfamilies(&numOpfamilies);
125+
120126
if (g_verbose)
121127
write_msg(NULL,"reading user-defined conversions\n");
122128
convinfo=getConversions(&numConversions);

‎src/bin/pg_dump/pg_backup_archiver.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*
1616
*
1717
* IDENTIFICATION
18-
*$PostgreSQL: pgsql/src/bin/pg_dump/pg_backup_archiver.c,v 1.138 2006/11/21 22:19:46 tgl Exp $
18+
*$PostgreSQL: pgsql/src/bin/pg_dump/pg_backup_archiver.c,v 1.139 2007/01/23 17:54:50 tgl Exp $
1919
*
2020
*-------------------------------------------------------------------------
2121
*/
@@ -2443,7 +2443,8 @@ _getObjectDescription(PQExpBuffer buf, TocEntry *te, ArchiveHandle *AH)
24432443
if (strcmp(type,"AGGREGATE")==0||
24442444
strcmp(type,"FUNCTION")==0||
24452445
strcmp(type,"OPERATOR")==0||
2446-
strcmp(type,"OPERATOR CLASS")==0)
2446+
strcmp(type,"OPERATOR CLASS")==0||
2447+
strcmp(type,"OPERATOR FAMILY")==0)
24472448
{
24482449
/* Chop "DROP " off the front and make a modifiable copy */
24492450
char*first=strdup(te->dropStmt+5);
@@ -2571,6 +2572,7 @@ _printTocEntry(ArchiveHandle *AH, TocEntry *te, RestoreOptions *ropt, bool isDat
25712572
strcmp(te->desc,"FUNCTION")==0||
25722573
strcmp(te->desc,"OPERATOR")==0||
25732574
strcmp(te->desc,"OPERATOR CLASS")==0||
2575+
strcmp(te->desc,"OPERATOR FAMILY")==0||
25742576
strcmp(te->desc,"SCHEMA")==0||
25752577
strcmp(te->desc,"TABLE")==0||
25762578
strcmp(te->desc,"TYPE")==0||

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp