2222 *
2323 *
2424 * IDENTIFICATION
25- * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.253 2002/04/24 02:42:27 momjian Exp $
25+ * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.254 2002/04/24 02:44:19 momjian Exp $
2626 *
2727 *-------------------------------------------------------------------------
2828 */
@@ -574,7 +574,7 @@ dumpClasses(const TableInfo *tblinfo, const int numTables, Archive *fout,
574574if (tblinfo [i ].viewdef != NULL )
575575continue ;
576576
577- if (tblinfo [i ].sequence ) /* already dumped */
577+ if (tblinfo [i ].relkind == RELKIND_SEQUENCE ) /* already dumped */
578578continue ;
579579
580580if (!onlytable || (strcmp (classname ,onlytable )== 0 )|| (strlen (onlytable )== 0 ))
@@ -1672,7 +1672,7 @@ clearTableInfo(TableInfo *tblinfo, int numTables)
16721672if (tblinfo [i ].relname )
16731673free (tblinfo [i ].relname );
16741674
1675- if (tblinfo [i ].sequence )
1675+ if (tblinfo [i ].relkind == RELKIND_SEQUENCE )
16761676continue ;
16771677
16781678/* Process Attributes */
@@ -2212,7 +2212,6 @@ getTables(int *numTables, FuncInfo *finfo, int numFuncs, const char *tablename)
22122212tblinfo [i ].relname = strdup (PQgetvalue (res ,i ,i_relname ));
22132213tblinfo [i ].relacl = strdup (PQgetvalue (res ,i ,i_relacl ));
22142214tblinfo [i ].relkind = * (PQgetvalue (res ,i ,i_relkind ));
2215- tblinfo [i ].sequence = (tblinfo [i ].relkind == RELKIND_SEQUENCE );
22162215tblinfo [i ].hasindex = (strcmp (PQgetvalue (res ,i ,i_relhasindex ),"t" )== 0 );
22172216tblinfo [i ].hasoids = (strcmp (PQgetvalue (res ,i ,i_relhasoids ),"t" )== 0 );
22182217tblinfo [i ].usename = strdup (PQgetvalue (res ,i ,i_usename ));
@@ -2858,7 +2857,7 @@ getTableAttrs(TableInfo *tblinfo, int numTables)
28582857
28592858for (i = 0 ;i < numTables ;i ++ )
28602859{
2861- if (tblinfo [i ].sequence )
2860+ if (tblinfo [i ].relkind == RELKIND_SEQUENCE )
28622861continue ;
28632862
28642863/* find all the user attributes and their types */
@@ -4242,7 +4241,7 @@ dumpACL(Archive *fout, TableInfo tbinfo)
42424241}
42434242
42444243static void
4245- _dumpTableAttr70 (Archive * fout , TableInfo * tblinfo ,int i ,int j ,PQExpBuffer q )
4244+ _dumpTableAttr70 (TableInfo * tblinfo ,int i ,int j ,PQExpBuffer q )
42464245{
42474246int32 tmp_typmod ;
42484247int precision ;
@@ -4303,10 +4302,7 @@ _dumpTableAttr70(Archive *fout, TableInfo *tblinfo, int i, int j, PQExpBuffer q)
43034302
43044303void
43054304dumpTables (Archive * fout ,TableInfo * tblinfo ,int numTables ,
4306- IndInfo * indinfo ,int numIndexes ,
4307- InhInfo * inhinfo ,int numInherits ,
4308- TypeInfo * tinfo ,int numTypes ,const char * tablename ,
4309- const bool aclsSkip ,const bool oids ,
4305+ const char * tablename ,const bool aclsSkip ,
43104306const bool schemaOnly ,const bool dataOnly )
43114307{
43124308int i ,
@@ -4336,7 +4332,7 @@ dumpTables(Archive *fout, TableInfo *tblinfo, int numTables,
43364332}
43374333for (i = 0 ;i < numTables ;i ++ )
43384334{
4339- if (!( tblinfo [i ].sequence ) )
4335+ if (tblinfo [i ].relkind != RELKIND_SEQUENCE )
43404336continue ;
43414337if (!tablename || (!strcmp (tblinfo [i ].relname ,tablename ))
43424338|| (serialSeq && !strcmp (tblinfo [i ].relname ,serialSeq )))
@@ -4352,7 +4348,7 @@ dumpTables(Archive *fout, TableInfo *tblinfo, int numTables,
43524348
43534349for (i = 0 ;i < numTables ;i ++ )
43544350{
4355- if (tblinfo [i ].sequence ) /* already dumped */
4351+ if (tblinfo [i ].relkind == RELKIND_SEQUENCE ) /* already dumped */
43564352continue ;
43574353
43584354if (!tablename || (!strcmp (tblinfo [i ].relname ,tablename ))|| (strlen (tablename )== 0 ))
@@ -4415,7 +4411,7 @@ dumpTables(Archive *fout, TableInfo *tblinfo, int numTables,
44154411if (g_fout -> remoteVersion >=70100 )
44164412appendPQExpBuffer (q ,"%s" ,tblinfo [i ].atttypedefns [j ]);
44174413else
4418- _dumpTableAttr70 (fout , tblinfo ,i ,j ,q );
4414+ _dumpTableAttr70 (tblinfo ,i ,j ,q );
44194415
44204416/* Default value */
44214417if (tblinfo [i ].adef_expr [j ]!= NULL && tblinfo [i ].inhAttrDef [j ]== 0 )