mirror of
https://github.com/postgres/postgres.git
synced 2025-07-24 14:22:24 +03:00
Adjust pg_dump tag for relation stats.
Do not use fmtId(), just use dobj->name directly, like for table data.
This commit is contained in:
@ -10490,7 +10490,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
|
|||||||
PGresult *res;
|
PGresult *res;
|
||||||
PQExpBuffer query;
|
PQExpBuffer query;
|
||||||
PQExpBuffer out;
|
PQExpBuffer out;
|
||||||
PQExpBuffer tag;
|
|
||||||
DumpId *deps = NULL;
|
DumpId *deps = NULL;
|
||||||
int ndeps = 0;
|
int ndeps = 0;
|
||||||
char *qualified_name;
|
char *qualified_name;
|
||||||
@ -10522,9 +10521,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
|
|||||||
ndeps = dobj->nDeps;
|
ndeps = dobj->nDeps;
|
||||||
}
|
}
|
||||||
|
|
||||||
tag = createPQExpBuffer();
|
|
||||||
appendPQExpBufferStr(tag, fmtId(dobj->name));
|
|
||||||
|
|
||||||
query = createPQExpBuffer();
|
query = createPQExpBuffer();
|
||||||
if (!fout->is_prepared[PREPQUERY_GETATTRIBUTESTATS])
|
if (!fout->is_prepared[PREPQUERY_GETATTRIBUTESTATS])
|
||||||
{
|
{
|
||||||
@ -10695,7 +10691,7 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
|
|||||||
PQclear(res);
|
PQclear(res);
|
||||||
|
|
||||||
ArchiveEntry(fout, nilCatalogId, createDumpId(),
|
ArchiveEntry(fout, nilCatalogId, createDumpId(),
|
||||||
ARCHIVE_OPTS(.tag = tag->data,
|
ARCHIVE_OPTS(.tag = dobj->name,
|
||||||
.namespace = dobj->namespace->dobj.name,
|
.namespace = dobj->namespace->dobj.name,
|
||||||
.description = "STATISTICS DATA",
|
.description = "STATISTICS DATA",
|
||||||
.section = rsinfo->postponed_def ?
|
.section = rsinfo->postponed_def ?
|
||||||
@ -10707,7 +10703,6 @@ dumpRelationStats(Archive *fout, const RelStatsInfo *rsinfo)
|
|||||||
free(qualified_name);
|
free(qualified_name);
|
||||||
destroyPQExpBuffer(out);
|
destroyPQExpBuffer(out);
|
||||||
destroyPQExpBuffer(query);
|
destroyPQExpBuffer(query);
|
||||||
destroyPQExpBuffer(tag);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Reference in New Issue
Block a user