|
PostgreSQL Source Code git master
|
#include "postgres.h"#include "common/int.h"#include "common/jsonapi.h"#include "lib/stringinfo.h"#include "mb/pg_wchar.h"#include "nodes/miscnodes.h"#include "statistics/extended_stats_internal.h"#include "statistics/statistics_format.h"#include "utils/builtins.h"#include "utils/float.h"#include "utils/fmgrprotos.h"
Go to the source code of this file.
Data Structures | |
| struct | DependenciesParseState |
Enumerations | |
| enum | DependenciesSemanticState { DEPS_EXPECT_START = 0 , DEPS_EXPECT_ITEM , DEPS_EXPECT_KEY , DEPS_EXPECT_ATTNUM_LIST , DEPS_EXPECT_ATTNUM , DEPS_EXPECT_DEPENDENCY , DEPS_EXPECT_DEGREE , DEPS_PARSE_COMPLETE } |
| Enumerator | |
|---|---|
| DEPS_EXPECT_START | |
| DEPS_EXPECT_ITEM | |
| DEPS_EXPECT_KEY | |
| DEPS_EXPECT_ATTNUM_LIST | |
| DEPS_EXPECT_ATTNUM | |
| DEPS_EXPECT_DEPENDENCY | |
| DEPS_EXPECT_DEGREE | |
| DEPS_PARSE_COMPLETE | |
Definition at line 28 of file pg_dependencies.c.
|
static |
Definition at line 655 of file pg_dependencies.c.
References dep_attnum_dependency(), dep_attnum_list(), dep_attributes_eq(), MVDependencies::deps, DEPS_EXPECT_START, DEPS_PARSE_COMPLETE, elog, errcode(), errdetail(), errmsg(), ERROR, errsave, i, j, list_length(), list_nth(), MVDependencies::magic, MVDependencies::ndeps, palloc0(), parse(), pfree(), PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEPENDENCY, statext_dependencies_serialize(), STATS_DEPS_MAGIC, STATS_DEPS_TYPE_BASIC, str, and MVDependencies::type.
Referenced by pg_dependencies_in().
|
static |
Definition at line 642 of file pg_dependencies.c.
References MVDependency::attributes, and MVDependency::nattributes.
Referenced by build_mvdependencies().
|
static |
Definition at line 624 of file pg_dependencies.c.
References appendStringInfo(), MVDependency::attributes, i, initStringInfo(), MVDependency::nattributes, and str.
Referenced by build_mvdependencies().
|
static |
Definition at line 600 of file pg_dependencies.c.
Referenced by build_mvdependencies().
|
static |
Definition at line 419 of file pg_dependencies.c.
References DEPS_EXPECT_ATTNUM, DEPS_EXPECT_ITEM, errcode(), errdetail(), errmsg(), errsave, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, and parse().
Referenced by pg_dependencies_in().
|
static |
Definition at line 290 of file pg_dependencies.c.
References DEPS_EXPECT_ATTNUM, DEPS_EXPECT_ITEM, DEPS_EXPECT_KEY, DEPS_PARSE_COMPLETE, errcode(), errdetail(), errmsg(), errsave, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, list_length(), parse(), and PG_DEPENDENCIES_KEY_ATTRIBUTES.
Referenced by pg_dependencies_in().
|
static |
Definition at line 261 of file pg_dependencies.c.
References DEPS_EXPECT_ATTNUM, DEPS_EXPECT_ATTNUM_LIST, DEPS_EXPECT_ITEM, DEPS_EXPECT_START, errcode(), errdetail(), errmsg(), errsave, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, and parse().
Referenced by pg_dependencies_in().
|
static |
Definition at line 143 of file pg_dependencies.c.
References MVDependency::attributes, MVDependency::degree, DEPS_EXPECT_ITEM, DEPS_EXPECT_KEY, errcode(), errdetail(), errmsg(), errsave, i, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, lappend(), list_free(), list_length(), list_nth_int(), MVDependency::nattributes, NIL, palloc0(), parse(), PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEGREE, PG_DEPENDENCIES_KEY_DEPENDENCY, and STATS_MAX_DIMENSIONS.
Referenced by pg_dependencies_in().
|
static |
Definition at line 347 of file pg_dependencies.c.
References DEPS_EXPECT_ATTNUM_LIST, DEPS_EXPECT_DEGREE, DEPS_EXPECT_DEPENDENCY, errcode(), errdetail(), errmsg(), errsave, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, parse(), PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEGREE, and PG_DEPENDENCIES_KEY_DEPENDENCY.
Referenced by pg_dependencies_in().
|
static |
Definition at line 64 of file pg_dependencies.c.
References DEPS_EXPECT_ATTNUM, DEPS_EXPECT_ATTNUM_LIST, DEPS_EXPECT_DEGREE, DEPS_EXPECT_DEPENDENCY, DEPS_EXPECT_ITEM, DEPS_EXPECT_KEY, DEPS_EXPECT_START, errcode(), errdetail(), errmsg(), errsave, JSON_SEM_ACTION_FAILED, JSON_SUCCESS, parse(), PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEGREE, and PG_DEPENDENCIES_KEY_DEPENDENCY.
Referenced by pg_dependencies_in().
|
static |
Definition at line 486 of file pg_dependencies.c.
References attnum, DEPS_EXPECT_ATTNUM, DEPS_EXPECT_DEGREE, DEPS_EXPECT_DEPENDENCY, DEPS_EXPECT_KEY, errcode(), errdetail(), errmsg(), errsave, float8in_internal(), JSON_SEM_ACTION_FAILED, JSON_SUCCESS, lappend_int(), llast_int, NIL, parse(), PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEGREE, PG_DEPENDENCIES_KEY_DEPENDENCY, pg_strtoint16_safe(), STATS_MAX_DIMENSIONS, and valid_subsequent_attnum().
Referenced by pg_dependencies_in().
| Datum pg_dependencies_in | ( | PG_FUNCTION_ARGS | ) |
Definition at line 755 of file pg_dependencies.c.
References JsonSemAction::array_element_end, JsonSemAction::array_element_start, JsonSemAction::array_end, JsonSemAction::array_start, DependenciesParseState::attnum_list, build_mvdependencies(), DependenciesParseState::degree, dependencies_array_element_start(), dependencies_array_end(), dependencies_array_start(), dependencies_object_end(), dependencies_object_field_start(), dependencies_object_start(), dependencies_scalar(), DependenciesParseState::dependency, DependenciesParseState::dependency_list, DEPS_EXPECT_START, errcode(), errdetail(), errmsg(), errsave, DependenciesParseState::escontext, DependenciesParseState::found_attributes, DependenciesParseState::found_degree, DependenciesParseState::found_dependency, freeJsonLexContext(), JSON_SUCCESS, list_free(), list_free_deep(), makeJsonLexContextCstringLen(), NIL, JsonSemAction::object_end, JsonSemAction::object_field_end, JsonSemAction::object_field_start, JsonSemAction::object_start, PG_GETARG_CSTRING, pg_parse_json(), PG_RETURN_BYTEA_P, PG_RETURN_NULL, PG_UTF8, JsonSemAction::scalar, JsonSemAction::semstate, SOFT_ERROR_OCCURRED, DependenciesParseState::state, DependenciesParseState::str, and str.
| Datum pg_dependencies_out | ( | PG_FUNCTION_ARGS | ) |
Definition at line 821 of file pg_dependencies.c.
References appendStringInfo(), appendStringInfoChar(), appendStringInfoString(), MVDependency::attributes, data, MVDependency::degree, MVDependencies::deps, elog, ERROR, i, initStringInfo(), j, MVDependency::nattributes, MVDependencies::ndeps, PG_DEPENDENCIES_KEY_ATTRIBUTES, PG_DEPENDENCIES_KEY_DEGREE, PG_DEPENDENCIES_KEY_DEPENDENCY, PG_GETARG_BYTEA_PP, PG_RETURN_CSTRING, statext_dependencies_deserialize(), and str.
| Datum pg_dependencies_recv | ( | PG_FUNCTION_ARGS | ) |
Definition at line 861 of file pg_dependencies.c.
References ereport, errcode(), errmsg(), ERROR, and PG_RETURN_VOID.
| Datum pg_dependencies_send | ( | PG_FUNCTION_ARGS | ) |
|
static |
Definition at line 469 of file pg_dependencies.c.
Referenced by dependencies_scalar().