PostgreSQL Source Code
git master
|
#include "postgres.h"
#include "catalog/pg_aggregate.h"
#include "catalog/pg_proc.h"
#include "catalog/pg_type.h"
#include "commands/dbcommands.h"
#include "miscadmin.h"
#include "nodes/makefuncs.h"
#include "nodes/nodeFuncs.h"
#include "optimizer/optimizer.h"
#include "parser/analyze.h"
#include "parser/parse_agg.h"
#include "parser/parse_clause.h"
#include "parser/parse_coerce.h"
#include "parser/parse_collate.h"
#include "parser/parse_expr.h"
#include "parser/parse_func.h"
#include "parser/parse_oper.h"
#include "parser/parse_relation.h"
#include "parser/parse_target.h"
#include "parser/parse_type.h"
#include "utils/builtins.h"
#include "utils/date.h"
#include "utils/fmgroids.h"
#include "utils/lsyscache.h"
#include "utils/timestamp.h"
#include "utils/xml.h"
Go to the source code of this file.
Variables | |
bool | Transform_null_equals = false |
|
static |
Definition at line 4157 of file parse_expr.c.
References copyObject, exprType(), JsonReturning::format, JsonFormat::format_type, JS_FORMAT_DEFAULT, JS_FORMAT_JSONB, JsonReturning::typid, and JsonReturning::typmod.
Referenced by transformJsonFuncExprOutput().
|
static |
Definition at line 3423 of file parse_expr.c.
References enc, ereport, errcode(), errhint(), errmsg(), ERROR, format, get_type_category_preferred(), JS_ENC_DEFAULT, JS_ENC_UTF8, JS_FORMAT_DEFAULT, JS_FORMAT_JSON, and parser_errposition().
Referenced by transformJsonOutput().
|
static |
Definition at line 4263 of file parse_expr.c.
References COERCE_IMPLICIT_CAST, coerce_to_target_type(), COERCION_EXPLICIT, ereport, errcode(), errmsg(), ERROR, exprLocation(), exprType(), format_type_be(), JsonExpr::location, parser_errposition(), JsonExpr::returning, JsonReturning::typid, and JsonReturning::typmod.
Referenced by transformJsonFuncExpr().
|
static |
Definition at line 4179 of file parse_expr.c.
References coerceJsonFuncExpr(), JsonCoercion::expr, get_typtype(), makeNode, type_is_array, JsonReturning::typid, JsonCoercion::via_io, and JsonCoercion::via_populate.
Referenced by initJsonItemCoercion(), and transformJsonFuncExprOutput().
|
static |
Definition at line 3558 of file parse_expr.c.
References COERCE_EXPLICIT_CALL, COERCE_EXPLICIT_CAST, coerce_to_specific_type(), coerce_to_target_type(), COERCION_EXPLICIT, enc, ereport, errcode(), errmsg(), ERROR, exprLocation(), exprType(), JsonReturning::format, JsonFormat::format_type, format_type_be(), getJsonEncodingConst(), InvalidOid, JS_FORMAT_JSON, list_make2, FuncExpr::location, JsonFormat::location, makeFuncExpr(), OidIsValid, parser_coercion_errposition(), res, JsonReturning::typid, and JsonReturning::typmod.
Referenced by coerceJsonExpr(), and makeJsonConstructorExpr().
Definition at line 910 of file parse_expr.c.
References arg, IsA, and A_Const::isnull.
Referenced by transformAExprDistinct(), and transformAExprOp().
|
static |
Definition at line 3175 of file parse_expr.c.
References elog, enc, encoding, ERROR, format, InvalidOid, JS_ENC_DEFAULT, JS_ENC_UTF16, JS_ENC_UTF32, JS_ENC_UTF8, JS_FORMAT_DEFAULT, makeConst(), NAMEDATALEN, NameGetDatum, namestrcpy(), and palloc().
Referenced by coerceJsonFuncExpr(), and makeJsonByteaToTextConversion().
|
static |
Definition at line 4302 of file parse_expr.c.
References coerceJsonExpr(), CaseTestExpr::collation, InvalidOid, makeNode, makeNullConst(), CaseTestExpr::typeId, and CaseTestExpr::typeMod.
Referenced by initJsonItemCoercions().
|
static |
Definition at line 4326 of file parse_expr.c.
References JsonItemCoercions::boolean, JsonItemCoercions::composite, JsonItemCoercions::date, initJsonItemCoercion(), InvalidOid, JsonItemCoercions::null, JsonItemCoercions::numeric, JsonItemCoercions::string, JsonItemCoercions::time, JsonItemCoercions::timestamp, JsonItemCoercions::timestamptz, and JsonItemCoercions::timetz.
Referenced by transformJsonFuncExpr().
|
static |
Definition at line 3013 of file parse_expr.c.
References ereport, errcode(), errmsg(), ERROR, make_op(), NodeSetTag, ParseState::p_last_srf, parser_errposition(), and T_DistinctExpr.
Referenced by make_row_distinct_op(), and transformAExprDistinct().
|
static |
Definition at line 3046 of file parse_expr.c.
References AEXPR_NOT_DISTINCT, arg, NullTest::arg, NullTest::argisrow, IS_NOT_NULL, IS_NULL, A_Expr::kind, A_Expr::location, NullTest::location, makeNode, NullTest::nulltesttype, and transformExprRecurse().
Referenced by transformAExprDistinct().
|
static |
Definition at line 2767 of file parse_expr.c.
References AND_EXPR, bms_add_member(), bms_first_member(), bms_int_members(), castNode, cmp(), ereport, errcode(), errdetail(), errhint(), errmsg(), ERROR, expression_returns_set(), forboth, format_type_be(), get_op_btree_interpretation(), i, RowCompareExpr::inputcollids, InvalidOid, j, lappend(), lappend_oid(), RowCompareExpr::largs, lfirst, linitial, list_length(), llast, lsecond, make_op(), makeBoolExpr(), makeNode, NIL, OidIsValid, RowCompareExpr::opfamilies, OpBtreeInterpretation::opfamily_id, RowCompareExpr::opnos, OR_EXPR, ParseState::p_last_srf, palloc(), parser_errposition(), RowCompareExpr::rargs, RowCompareExpr::rctype, ROWCOMPARE_EQ, ROWCOMPARE_NE, OpBtreeInterpretation::strategy, and strVal.
Referenced by transformAExprIn(), transformAExprOp(), and transformSubLink().
|
static |
Definition at line 2969 of file parse_expr.c.
References RowExpr::args, cmp(), ereport, errcode(), errmsg(), ERROR, forboth, lfirst, list_length(), list_make2, make_distinct_op(), makeBoolConst(), makeBoolExpr(), OR_EXPR, and parser_errposition().
Referenced by transformAExprDistinct().
Definition at line 3231 of file parse_expr.c.
References CaseTestExpr::collation, exprCollation(), exprType(), exprTypmod(), makeNode, CaseTestExpr::typeId, and CaseTestExpr::typeMod.
Referenced by makeJsonConstructorExpr(), transformJsonFuncExprOutput(), transformJsonParseArg(), and transformJsonValueExprExt().
|
static |
Definition at line 3214 of file parse_expr.c.
References COERCE_EXPLICIT_CALL, encoding, format, getJsonEncodingConst(), InvalidOid, list_make2, FuncExpr::location, and makeFuncExpr().
Referenced by transformJsonParseArg(), and transformJsonValueExprExt().
|
static |
Definition at line 3612 of file parse_expr.c.
References JsonConstructorExpr::absent_on_null, generate_unaccent_rules::args, JsonConstructorExpr::args, coerceJsonFuncExpr(), JsonConstructorExpr::coercion, CaseTestExpr::collation, JsonReturning::format, JsonFormat::format_type, JsonConstructorExpr::func, InvalidOid, JS_FORMAT_JSONB, JsonConstructorExpr::location, makeCaseTestExpr(), makeNode, JsonConstructorExpr::returning, generate_unaccent_rules::type, JsonConstructorExpr::type, CaseTestExpr::typeId, CaseTestExpr::typeMod, and JsonConstructorExpr::unique.
Referenced by transformJsonAggConstructor(), transformJsonArrayConstructor(), transformJsonObjectConstructor(), transformJsonParseExpr(), transformJsonScalarExpr(), and transformJsonSerializeExpr().
const char* ParseExprKindName | ( | ParseExprKind | exprKind | ) |
Definition at line 3070 of file parse_expr.c.
References EXPR_KIND_ALTER_COL_TRANSFORM, EXPR_KIND_CALL_ARGUMENT, EXPR_KIND_CHECK_CONSTRAINT, EXPR_KIND_COLUMN_DEFAULT, EXPR_KIND_COPY_WHERE, EXPR_KIND_CYCLE_MARK, EXPR_KIND_DISTINCT_ON, EXPR_KIND_DOMAIN_CHECK, EXPR_KIND_EXECUTE_PARAMETER, EXPR_KIND_FILTER, EXPR_KIND_FROM_FUNCTION, EXPR_KIND_FROM_SUBSELECT, EXPR_KIND_FUNCTION_DEFAULT, EXPR_KIND_GENERATED_COLUMN, EXPR_KIND_GROUP_BY, EXPR_KIND_HAVING, EXPR_KIND_INDEX_EXPRESSION, EXPR_KIND_INDEX_PREDICATE, EXPR_KIND_INSERT_TARGET, EXPR_KIND_JOIN_ON, EXPR_KIND_JOIN_USING, EXPR_KIND_LIMIT, EXPR_KIND_MERGE_WHEN, EXPR_KIND_NONE, EXPR_KIND_OFFSET, EXPR_KIND_ORDER_BY, EXPR_KIND_OTHER, EXPR_KIND_PARTITION_BOUND, EXPR_KIND_PARTITION_EXPRESSION, EXPR_KIND_POLICY, EXPR_KIND_RETURNING, EXPR_KIND_SELECT_TARGET, EXPR_KIND_STATS_EXPRESSION, EXPR_KIND_TRIGGER_WHEN, EXPR_KIND_UPDATE_SOURCE, EXPR_KIND_UPDATE_TARGET, EXPR_KIND_VALUES, EXPR_KIND_VALUES_SINGLE, EXPR_KIND_WHERE, EXPR_KIND_WINDOW_FRAME_GROUPS, EXPR_KIND_WINDOW_FRAME_RANGE, EXPR_KIND_WINDOW_FRAME_ROWS, EXPR_KIND_WINDOW_ORDER, and EXPR_KIND_WINDOW_PARTITION.
Referenced by check_agglevels_and_constraints(), check_srf_call_placement(), checkTargetlistEntrySQL92(), findTargetlistEntrySQL92(), and transformWindowFuncCall().
|
static |
Definition at line 1283 of file parse_expr.c.
References a, AEXPR_BETWEEN, AEXPR_BETWEEN_SYM, AEXPR_NOT_BETWEEN, AEXPR_NOT_BETWEEN_SYM, AEXPR_OP, AND_EXPR, generate_unaccent_rules::args, Assert(), castNode, copyObject, elog, ERROR, linitial, list_length(), list_make2, lsecond, makeBoolExpr(), makeSimpleA_Expr(), OR_EXPR, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1032 of file parse_expr.c.
References a, AEXPR_NOT_DISTINCT, exprIsNullConstant(), IsA, list_make1, make_distinct_op(), make_nulltest_from_distinct(), make_row_distinct_op(), makeBoolExpr(), NOT_EXPR, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1125 of file parse_expr.c.
References a, AND_EXPR, generate_unaccent_rules::args, ArrayExpr::array_typeid, cmp(), coerce_to_boolean(), coerce_to_common_type(), contain_vars_of_level(), copyObject, ArrayExpr::element_typeid, ArrayExpr::elements, get_array_type(), InvalidOid, IsA, lappend(), lfirst, linitial, list_concat(), list_length(), list_make1, list_make2, ArrayExpr::location, make_op(), make_row_comparison_op(), make_scalar_array_op(), makeBoolExpr(), makeNode, ArrayExpr::multidims, NIL, OidIsValid, OR_EXPR, ParseState::p_last_srf, select_common_type(), strVal, transformExprRecurse(), and verify_common_type().
Referenced by transformExprRecurse().
|
static |
Definition at line 1083 of file parse_expr.c.
References a, OpExpr::args, ereport, errcode(), errmsg(), ERROR, exprType(), linitial, make_op(), NodeSetTag, OpExpr::opresulttype, OpExpr::opretset, ParseState::p_last_srf, parser_errposition(), T_NullIfExpr, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 923 of file parse_expr.c.
References a, NullTest::arg, generate_unaccent_rules::args, castNode, EXPR_SUBLINK, exprIsNullConstant(), IS_NULL, IsA, linitial, list_length(), SubLink::location, NullTest::location, make_op(), make_row_comparison_op(), makeNode, NullTest::nulltesttype, SubLink::operName, ParseState::p_last_srf, ROWCOMPARE_SUBLINK, strVal, SubLink::subLinkType, SubLink::testexpr, Transform_null_equals, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1018 of file parse_expr.c.
References a, make_scalar_array_op(), and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1004 of file parse_expr.c.
References a, make_scalar_array_op(), and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1988 of file parse_expr.c.
References a, ArrayExpr::array_typeid, Assert(), COERCE_EXPLICIT_CAST, coerce_to_common_type(), coerce_to_target_type(), coerce_type(), COERCION_EXPLICIT, element(), ArrayExpr::element_typeid, ArrayExpr::elements, ereport, errcode(), errhint(), errmsg(), ERROR, exprLocation(), exprType(), format_type_be(), get_array_type(), get_element_type(), InvalidOid, IsA, lappend(), lfirst, ArrayExpr::location, makeNode, ArrayExpr::multidims, NIL, OidIsValid, parser_errposition(), select_common_type(), transformExprRecurse(), and type_is_array.
Referenced by transformExprRecurse(), and transformTypeCast().
|
static |
Definition at line 2484 of file parse_expr.c.
References b, coerce_to_boolean(), elog, ERROR, IS_FALSE, IS_NOT_FALSE, IS_NOT_TRUE, IS_NOT_UNKNOWN, IS_TRUE, IS_UNKNOWN, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1377 of file parse_expr.c.
References a, AND_EXPR, arg, generate_unaccent_rules::args, coerce_to_boolean(), elog, ERROR, lappend(), lfirst, makeBoolExpr(), NIL, NOT_EXPR, OR_EXPR, and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 1606 of file parse_expr.c.
References AEXPR_OP, arg, CaseExpr::arg, CaseExpr::args, Assert(), assign_expr_collations(), CaseExpr::casetype, coerce_to_boolean(), coerce_to_common_type(), CaseTestExpr::collation, CaseExpr::defresult, ereport, errcode(), errhint(), errmsg(), ERROR, CaseWhen::expr, exprCollation(), exprLocation(), exprType(), exprTypmod(), if(), A_Const::isnull, lappend(), lcons(), lfirst, lfirst_node, A_Const::location, CaseExpr::location, CaseWhen::location, makeNode, makeSimpleA_Expr(), NIL, OidIsValid, ParseState::p_last_srf, parser_errposition(), CaseWhen::result, select_common_type(), transformExprRecurse(), CaseTestExpr::typeId, and CaseTestExpr::typeMod.
Referenced by transformExprRecurse().
|
static |
Definition at line 2171 of file parse_expr.c.
References generate_unaccent_rules::args, CoalesceExpr::args, CoalesceExpr::coalescetype, coerce_to_common_type(), ereport, errcode(), errhint(), errmsg(), ERROR, exprLocation(), lappend(), lfirst, CoalesceExpr::location, makeNode, NIL, ParseState::p_last_srf, parser_errposition(), select_common_type(), and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 2727 of file parse_expr.c.
References CollateExpr::arg, CollateExpr::collOid, ereport, errcode(), errmsg(), ERROR, exprType(), format_type_be(), CollateExpr::location, LookupCollation(), makeNode, parser_errposition(), transformExprRecurse(), and type_is_collatable().
Referenced by transformExprRecurse().
|
static |
Definition at line 501 of file parse_expr.c.
References _, Assert(), colNameToVar(), ereport, errcode(), errmsg(), errmsg_internal(), ERROR, errorMissingColumn(), errorMissingRTE(), EXPR_KIND_ALTER_COL_TRANSFORM, EXPR_KIND_CALL_ARGUMENT, EXPR_KIND_CHECK_CONSTRAINT, EXPR_KIND_COLUMN_DEFAULT, EXPR_KIND_COPY_WHERE, EXPR_KIND_CYCLE_MARK, EXPR_KIND_DISTINCT_ON, EXPR_KIND_DOMAIN_CHECK, EXPR_KIND_EXECUTE_PARAMETER, EXPR_KIND_FILTER, EXPR_KIND_FROM_FUNCTION, EXPR_KIND_FROM_SUBSELECT, EXPR_KIND_FUNCTION_DEFAULT, EXPR_KIND_GENERATED_COLUMN, EXPR_KIND_GROUP_BY, EXPR_KIND_HAVING, EXPR_KIND_INDEX_EXPRESSION, EXPR_KIND_INDEX_PREDICATE, EXPR_KIND_INSERT_TARGET, EXPR_KIND_JOIN_ON, EXPR_KIND_JOIN_USING, EXPR_KIND_LIMIT, EXPR_KIND_MERGE_WHEN, EXPR_KIND_NONE, EXPR_KIND_OFFSET, EXPR_KIND_ORDER_BY, EXPR_KIND_OTHER, EXPR_KIND_PARTITION_BOUND, EXPR_KIND_PARTITION_EXPRESSION, EXPR_KIND_POLICY, EXPR_KIND_RETURNING, EXPR_KIND_SELECT_TARGET, EXPR_KIND_STATS_EXPRESSION, EXPR_KIND_TRIGGER_WHEN, EXPR_KIND_UPDATE_SOURCE, EXPR_KIND_UPDATE_TARGET, EXPR_KIND_VALUES, EXPR_KIND_VALUES_SINGLE, EXPR_KIND_WHERE, EXPR_KIND_WINDOW_FRAME_GROUPS, EXPR_KIND_WINDOW_FRAME_RANGE, EXPR_KIND_WINDOW_FRAME_ROWS, EXPR_KIND_WINDOW_ORDER, EXPR_KIND_WINDOW_PARTITION, ColumnRef::fields, get_database_name(), IsA, lfourth, linitial, list_length(), list_make1, ColumnRef::location, lsecond, lthird, makeRangeVar(), makeString(), MyDatabaseId, NameListToString(), ParseState::p_expr_kind, ParseState::p_last_srf, ParseState::p_post_columnref_hook, ParseState::p_pre_columnref_hook, ParseFuncOrColumn(), parser_errposition(), refnameNamespaceItem(), relname, scanNSItemForColumn(), strVal, and transformWholeRowRef().
Referenced by transformExprRecurse().
|
static |
Definition at line 2524 of file parse_expr.c.
References Assert(), CurrentOfExpr::cursor_name, CurrentOfExpr::cursor_param, CurrentOfExpr::cvarno, ColumnRef::fields, IsA, list_make1, ColumnRef::location, makeNode, makeString(), ParseState::p_post_columnref_hook, ParseState::p_pre_columnref_hook, ParseNamespaceItem::p_rtindex, ParseState::p_target_nsitem, PARAM_EXTERN, Param::paramid, Param::paramkind, and Param::paramtype.
Referenced by transformExprRecurse().
Node* transformExpr | ( | ParseState * | pstate, |
Node * | expr, | ||
ParseExprKind | exprKind | ||
) |
Definition at line 112 of file parse_expr.c.
References Assert(), EXPR_KIND_NONE, ParseState::p_expr_kind, and transformExprRecurse().
Referenced by analyzeCTE(), appendJsonTableColumns(), array_subscript_transform(), cookConstraint(), cookDefault(), DoCopy(), domainAddConstraint(), EvaluateParams(), ExpandIndirectionStar(), findTargetlistEntrySQL99(), hstore_subscript_transform(), interpret_function_parameter_list(), jsonb_subscript_transform(), resolve_unique_index_expr(), transformAlterTableStmt(), transformCallStmt(), transformExpressionList(), transformFrameOffset(), transformFuncCall(), transformGroupingFunc(), transformIndexStmt(), transformJoinUsingClause(), transformJsonTable(), transformLimitClause(), transformMergeStmt(), transformOnConflictArbiter(), transformPartitionBoundValue(), transformPartitionSpec(), transformPLAssignStmt(), transformRangeFunction(), transformRangeTableFunc(), transformRangeTableSample(), transformReturnStmt(), transformStatsStmt(), transformTargetEntry(), and transformWhereClause().
|
static |
Definition at line 130 of file parse_expr.c.
References a, AEXPR_BETWEEN, AEXPR_BETWEEN_SYM, AEXPR_DISTINCT, AEXPR_ILIKE, AEXPR_IN, AEXPR_LIKE, AEXPR_NOT_BETWEEN, AEXPR_NOT_BETWEEN_SYM, AEXPR_NOT_DISTINCT, AEXPR_NULLIF, AEXPR_OP, AEXPR_OP_ALL, AEXPR_OP_ANY, AEXPR_SIMILAR, NamedArgExpr::arg, NullTest::arg, NullTest::argisrow, check_stack_depth(), elog, ereport, errcode(), errmsg(), ERROR, exprType(), InvalidOid, make_const(), nodeTag, parser_errposition(), T_A_ArrayExpr, T_A_Const, T_A_Expr, T_A_Indirection, T_BooleanTest, T_BoolExpr, T_CaseExpr, T_CaseTestExpr, T_CoalesceExpr, T_CollateClause, T_ColumnRef, T_CurrentOfExpr, T_FuncCall, T_GroupingFunc, T_JsonArrayAgg, T_JsonArrayConstructor, T_JsonArrayQueryConstructor, T_JsonFuncExpr, T_JsonIsPredicate, T_JsonObjectAgg, T_JsonObjectConstructor, T_JsonParseExpr, T_JsonScalarExpr, T_JsonSerializeExpr, T_JsonValueExpr, T_MinMaxExpr, T_MultiAssignRef, T_NamedArgExpr, T_NullTest, T_ParamRef, T_RowExpr, T_SetToDefault, T_SQLValueFunction, T_SubLink, T_TypeCast, T_Var, T_XmlExpr, T_XmlSerialize, transformAExprBetween(), transformAExprDistinct(), transformAExprIn(), transformAExprNullIf(), transformAExprOp(), transformAExprOpAll(), transformAExprOpAny(), transformArrayExpr(), transformBooleanTest(), transformBoolExpr(), transformCaseExpr(), transformCoalesceExpr(), transformCollateClause(), transformColumnRef(), transformCurrentOfExpr(), transformFuncCall(), transformGroupingFunc(), transformIndirection(), transformJsonArrayAgg(), transformJsonArrayConstructor(), transformJsonArrayQueryConstructor(), transformJsonFuncExpr(), transformJsonIsPredicate(), transformJsonObjectAgg(), transformJsonObjectConstructor(), transformJsonParseExpr(), transformJsonScalarExpr(), transformJsonSerializeExpr(), transformJsonValueExpr(), transformMinMaxExpr(), transformMultiAssignRef(), transformParamRef(), transformRowExpr(), transformSQLValueFunction(), transformSubLink(), transformTypeCast(), transformXmlExpr(), transformXmlSerialize(), and type_is_rowtype().
Referenced by make_nulltest_from_distinct(), transformAExprBetween(), transformAExprDistinct(), transformAExprIn(), transformAExprNullIf(), transformAExprOp(), transformAExprOpAll(), transformAExprOpAny(), transformArrayExpr(), transformBooleanTest(), transformBoolExpr(), transformCaseExpr(), transformCoalesceExpr(), transformCollateClause(), transformExpr(), transformFuncCall(), transformIndirection(), transformJsonArrayQueryConstructor(), transformJsonBehavior(), transformJsonExprCommon(), transformJsonObjectAgg(), transformJsonObjectConstructor(), transformJsonParseArg(), transformJsonScalarExpr(), transformJsonValueExprExt(), transformMinMaxExpr(), transformMultiAssignRef(), transformSubLink(), transformTypeCast(), transformXmlExpr(), and transformXmlSerialize().
|
static |
Definition at line 1413 of file parse_expr.c.
References arg, generate_unaccent_rules::args, Assert(), EXPR_KIND_ORDER_BY, fn(), lappend(), lfirst, NIL, ParseState::p_last_srf, ParseFuncOrColumn(), transformExpr(), and transformExprRecurse().
Referenced by transformExprRecurse().
|
static |
Definition at line 429 of file parse_expr.c.
References Assert(), ereport, errcode(), errmsg(), ERROR, exprLocation(), exprType(), exprTypmod(), i, IsA, lappend(), lfirst, list_make1, NIL, ParseState::p_last_srf, ParseFuncOrColumn(), parser_errposition(), strVal, transformContainerSubscripts(), transformExprRecurse(), and unknown_attribute().
Referenced by transformExprRecurse().
|
static |
Definition at line 3761 of file parse_expr.c.
References JsonAggConstructor::agg_filter, JsonAggConstructor::agg_order, Aggref::aggfilter, WindowFunc::aggfilter, Aggref::aggfnoid, Aggref::aggkind, Aggref::aggsplit, AGGSPLIT_SIMPLE, Aggref::aggstar, Aggref::aggtranstype, Aggref::aggtype, Aggref::aggvariadic, generate_unaccent_rules::args, WindowFunc::args, CStringGetDatum, DatumGetInt32, DirectFunctionCall1, ereport, errcode(), errmsg(), ERROR, EXPR_KIND_FILTER, InvalidOid, JsonAggConstructor::location, Aggref::location, WindowFunc::location, makeJsonConstructorExpr(), makeNode, NIL, JsonAggConstructor::over, parser_errposition(), regprocin(), transformAggregateCall(), transformWhereClause(), transformWindowFuncCall(), WindowFunc::winagg, WindowFunc::winfnoid, WindowFunc::winstar, and WindowFunc::wintype.
Referenced by transformJsonArrayAgg(), and transformJsonObjectAgg().
|
static |
Definition at line 3903 of file parse_expr.c.
References JsonArrayAgg::absent_on_null, arg, JsonArrayAgg::arg, JsonArrayAgg::constructor, JsonReturning::format, JsonFormat::format_type, JS_FORMAT_JSONB, JSCTOR_JSON_ARRAYAGG, list_make1, JsonAggConstructor::output, transformJsonAggConstructor(), transformJsonConstructorOutput(), and transformJsonValueExprDefault().
Referenced by transformExprRecurse().
|
static |
Definition at line 3944 of file parse_expr.c.
References JsonArrayConstructor::absent_on_null, generate_unaccent_rules::args, castNode, JsonArrayConstructor::exprs, JSCTOR_JSON_ARRAY, lappend(), lfirst, JsonArrayConstructor::location, makeJsonConstructorExpr(), NIL, JsonArrayConstructor::output, transformJsonConstructorOutput(), transformJsonValueExprDefault(), and val.
Referenced by transformExprRecurse().
|
static |
Definition at line 3695 of file parse_expr.c.
References JsonArrayQueryConstructor::absent_on_null, JsonArrayAgg::absent_on_null, JsonAggConstructor::agg_order, Alias::aliasname, JsonArrayAgg::arg, Alias::colnames, JsonArrayAgg::constructor, count_nonjunk_tlist_entries(), ereport, errcode(), errmsg(), ERROR, EXPR_SUBLINK, ColumnRef::fields, JsonArrayQueryConstructor::format, free_parsestate(), ResTarget::indirection, list_make1, list_make2, ColumnRef::location, ResTarget::location, JsonArrayQueryConstructor::location, JsonAggConstructor::location, SubLink::location, make_parsestate(), makeJsonValueExpr(), makeNode, makeString(), ResTarget::name, NIL, SubLink::operName, JsonArrayQueryConstructor::output, JsonAggConstructor::output, parser_errposition(), pstrdup(), JsonArrayQueryConstructor::query, range(), select, SubLink::subLinkId, SubLink::subLinkType, SubLink::subselect, Query::targetList, SubLink::testexpr, transformExprRecurse(), transformStmt(), and ResTarget::val.
Referenced by transformExprRecurse().
|
static |
Definition at line 4071 of file parse_expr.c.
References JsonBehavior::btype, JsonBehavior::default_expr, JSON_BEHAVIOR_DEFAULT, makeJsonBehavior(), and transformExprRecurse().
Referenced by transformJsonExprCommon().
|
static |
Definition at line 3515 of file parse_expr.c.
References generate_unaccent_rules::args, exprType(), JsonReturning::format, JsonFormat::format_type, JS_FORMAT_JSON, JS_FORMAT_JSONB, lfirst, OidIsValid, output(), transformJsonOutput(), JsonReturning::typid, and JsonReturning::typmod.
Referenced by transformJsonArrayAgg(), transformJsonArrayConstructor(), transformJsonObjectAgg(), and transformJsonObjectConstructor().
|
static |
Definition at line 4476 of file parse_expr.c.
References Assert(), ereport, errcode(), errmsg(), ERROR, format, JsonReturning::format, format_type_be(), JS_ENC_DEFAULT, JS_FORMAT_JSON, makeJsonFormat(), makeNode, OidIsValid, output(), parser_errposition(), transformJsonOutput(), JsonReturning::typid, and JsonReturning::typmod.
Referenced by transformJsonParseExpr(), and transformJsonScalarExpr().
|
static |
Definition at line 4091 of file parse_expr.c.
References assign_expr_collations(), COERCE_IMPLICIT_CAST, coerce_to_target_type(), COERCION_EXPLICIT, JsonFuncExpr::common, ereport, errcode(), errmsg(), ERROR, JsonCommon::expr, exprLocation(), exprType(), format, JsonValueExpr::format, JsonExpr::format, format_type_be(), JsonExpr::formatted_expr, JS_FORMAT_JSON, JS_FORMAT_JSONB, JSON_BEHAVIOR_EMPTY, JSON_BEHAVIOR_FALSE, JSON_BEHAVIOR_NULL, JSON_EXISTS_OP, JSON_TABLE_OP, JsonFuncExpr::location, JsonExpr::location, makeNode, JsonExpr::omit_quotes, JsonFuncExpr::on_empty, JsonExpr::on_empty, JsonFuncExpr::on_error, JsonExpr::on_error, JsonFuncExpr::op, JsonExpr::op, parser_errposition(), JsonCommon::passing, JsonExpr::passing_names, JsonExpr::passing_values, JsonExpr::path_spec, JsonCommon::pathname, JsonCommon::pathspec, JsonExpr::result_coercion, transformExprRecurse(), transformJsonBehavior(), transformJsonPassingArgs(), and transformJsonValueExpr().
Referenced by transformJsonFuncExpr().
|
static |
Definition at line 4357 of file parse_expr.c.
References COERCE_IMPLICIT_CAST, coerce_to_target_type(), coerceDefaultJsonExpr(), COERCION_EXPLICIT, JsonExpr::coercions, CaseTestExpr::collation, JsonBehavior::default_expr, JsonFormat::encoding, ereport, errcode(), errhint(), errmsg(), ERROR, exprLocation(), exprType(), JsonReturning::format, JsonFormat::format_type, format_type_be(), JsonExpr::formatted_expr, initJsonItemCoercions(), InvalidOid, JS_ENC_DEFAULT, JS_FORMAT_DEFAULT, JSON_EXISTS_OP, JSON_QUERY_OP, JSON_TABLE_OP, JSON_VALUE_OP, JsonFuncExpr::location, makeJsonFormat(), makeNode, OidIsValid, JsonFuncExpr::omit_quotes, JsonExpr::omit_quotes, JsonExpr::on_empty, JsonExpr::on_error, JsonFuncExpr::op, JsonFuncExpr::output, parser_coercion_errposition(), parser_errposition(), JsonExpr::returning, transformJsonExprCommon(), transformJsonFuncExprOutput(), transformJsonOutput(), CaseTestExpr::typeId, CaseTestExpr::typeMod, JsonReturning::typid, JsonReturning::typmod, JsonFuncExpr::wrapper, and JsonExpr::wrapper.
Referenced by transformExprRecurse().
|
static |
Definition at line 4211 of file parse_expr.c.
References Assert(), assignDefaultJsonReturningType(), coerceJsonExpr(), JsonCoercion::expr, JsonExpr::format, JsonExpr::formatted_expr, JSON_VALUE_OP, makeCaseTestExpr(), makeNode, OidIsValid, JsonFuncExpr::op, JsonFuncExpr::output, JsonExpr::result_coercion, JsonExpr::returning, transformJsonOutput(), JsonReturning::typid, JsonReturning::typmod, and JsonCoercion::via_io.
Referenced by transformJsonFuncExpr().
|
static |
Definition at line 4024 of file parse_expr.c.
References ereport, errcode(), errmsg(), ERROR, JsonIsPredicate::expr, JsonIsPredicate::format, format_type_be(), JsonIsPredicate::item_type, JsonIsPredicate::location, makeJsonIsPredicate(), transformJsonParseArg(), and JsonIsPredicate::unique_keys.
Referenced by transformExprRecurse().
|
static |
Definition at line 3844 of file parse_expr.c.
References JsonObjectAgg::absent_on_null, JsonObjectAgg::arg, generate_unaccent_rules::args, JsonObjectAgg::constructor, JsonReturning::format, JsonFormat::format_type, JS_FORMAT_JSONB, JSCTOR_JSON_OBJECTAGG, JsonKeyValue::key, sort-test::key, list_make2, JsonAggConstructor::output, transformExprRecurse(), transformJsonAggConstructor(), transformJsonConstructorOutput(), transformJsonValueExprDefault(), JsonObjectAgg::unique, val, and JsonKeyValue::value.
Referenced by transformExprRecurse().
|
static |
Definition at line 3661 of file parse_expr.c.
References JsonObjectConstructor::absent_on_null, generate_unaccent_rules::args, castNode, JsonObjectConstructor::exprs, JSCTOR_JSON_OBJECT, JsonKeyValue::key, sort-test::key, lappend(), lfirst, JsonObjectConstructor::location, makeJsonConstructorExpr(), NIL, JsonObjectConstructor::output, transformExprRecurse(), transformJsonConstructorOutput(), transformJsonValueExprDefault(), JsonObjectConstructor::unique, val, and JsonKeyValue::value.
Referenced by transformExprRecurse().
|
static |
Definition at line 3473 of file parse_expr.c.
References checkJsonOutputFormat(), copyObject, ereport, errcode(), errmsg(), ERROR, JsonReturning::format, JsonFormat::format_type, InvalidOid, JS_ENC_DEFAULT, JS_FORMAT_DEFAULT, JS_FORMAT_JSON, JS_FORMAT_JSONB, makeJsonFormat(), makeNode, output(), typenameTypeIdAndMod(), JsonReturning::typid, and JsonReturning::typmod.
Referenced by transformJsonConstructorOutput(), transformJsonConstructorRet(), transformJsonFuncExpr(), transformJsonFuncExprOutput(), and transformJsonSerializeExpr().
|
static |
Definition at line 3972 of file parse_expr.c.
References COERCE_IMPLICIT_CAST, coerce_to_target_type(), COERCION_IMPLICIT, ereport, errcode(), errmsg(), ERROR, exprLocation(), exprType(), format, JsonValueExpr::formatted_expr, get_type_category_preferred(), JS_ENC_DEFAULT, makeCaseTestExpr(), makeJsonByteaToTextConversion(), makeJsonValueExpr(), parser_errposition(), and transformExprRecurse().
Referenced by transformJsonIsPredicate(), and transformJsonParseExpr().
|
static |
Definition at line 4511 of file parse_expr.c.