PostgreSQL Source Code git master
|
#include "postgres.h"
#include "access/heapam.h"
#include "catalog/indexing.h"
#include "catalog/namespace.h"
#include "statistics/stat_utils.h"
#include "utils/builtins.h"
#include "utils/fmgroids.h"
#include "utils/fmgrprotos.h"
#include "utils/lsyscache.h"
#include "utils/syscache.h"
Go to the source code of this file.
Enumerations | |
enum | relation_stats_argnum { RELSCHEMA_ARG = 0 , RELNAME_ARG , RELPAGES_ARG , RELTUPLES_ARG , RELALLVISIBLE_ARG , RELALLFROZEN_ARG , NUM_RELATION_STATS_ARGS } |
Functions | |
static bool | relation_statistics_update (FunctionCallInfo fcinfo) |
Datum | pg_clear_relation_stats (PG_FUNCTION_ARGS) |
Datum | pg_restore_relation_stats (PG_FUNCTION_ARGS) |
Variables | |
static struct StatsArgInfo | relarginfo [] |
Enumerator | |
---|---|
RELSCHEMA_ARG | |
RELNAME_ARG | |
RELPAGES_ARG | |
RELTUPLES_ARG | |
RELALLVISIBLE_ARG | |
RELALLFROZEN_ARG | |
NUM_RELATION_STATS_ARGS |
Definition at line 36 of file relation_stats.c.
Datum pg_clear_relation_stats | ( | PG_FUNCTION_ARGS | ) |
Definition at line 200 of file relation_stats.c.
References Float4GetDatum(), InitFunctionCallInfoData, InvalidOid, LOCAL_FCINFO, PG_ARGISNULL, PG_GETARG_DATUM, PG_RETURN_VOID, relation_statistics_update(), and UInt32GetDatum().
Datum pg_restore_relation_stats | ( | PG_FUNCTION_ARGS | ) |
Definition at line 224 of file relation_stats.c.
References InitFunctionCallInfoData, InvalidOid, LOCAL_FCINFO, NUM_RELATION_STATS_ARGS, PG_RETURN_BOOL, relarginfo, relation_statistics_update(), and stats_fill_fcinfo_from_arg_pairs().
|
static |
Definition at line 64 of file relation_stats.c.
References CatalogTupleUpdate(), CommandCounterIncrement(), elog, ereport, errcode(), errhint(), errmsg(), ERROR, Float4GetDatum(), GETSTRUCT(), heap_freetuple(), heap_modify_tuple_by_cols(), HeapTupleIsValid, ObjectIdGetDatum(), PG_ARGISNULL, PG_GETARG_DATUM, PG_GETARG_FLOAT4, PG_GETARG_UINT32, RecoveryInProgress(), RELALLFROZEN_ARG, RELALLVISIBLE_ARG, relarginfo, RelationGetDescr, ReleaseSysCache(), relname, RELNAME_ARG, RELPAGES_ARG, RELSCHEMA_ARG, RELTUPLES_ARG, RowExclusiveLock, SearchSysCache1(), stats_check_required_arg(), stats_lock_check_privileges(), stats_lookup_relid(), HeapTupleData::t_self, table_close(), table_open(), TextDatumGetCString, UInt32GetDatum(), values, and WARNING.
Referenced by pg_clear_relation_stats(), and pg_restore_relation_stats().
|
static |
Definition at line 47 of file relation_stats.c.
Referenced by pg_restore_relation_stats(), and relation_statistics_update().