postgresql/src/backend/catalog
Tom Lane 858e776c84 Convert the reg* input functions to report (most) errors softly.
This is not really complete, but it catches most cases of practical
interest.  The main omissions are:

* regtype, regprocedure, and regoperator parse type names by
calling the main grammar, so any grammar-detected syntax error
will still be a hard error.  Also, if one includes a type
modifier in such a type specification, errors detected by the
typmodin function will be hard errors.

* Lookup errors are handled just by passing missing_ok = true
to the relevant catalog lookup function.  Because we've used
quite a restrictive definition of "missing_ok", this means that
edge cases such as "the named schema exists, but you lack
USAGE permission on it" are still hard errors.

It would make sense to me to replace most/all missing_ok
parameters with an escontext parameter and then allow these
additional lookup failure cases to be trapped too.  But that's
a job for some other day.

Discussion: https://postgr.es/m/3342239.1671988406@sss.pgh.pa.us
2022-12-27 12:26:01 -05:00
..
.gitignore Build in some knowledge about foreign-key relationships in the catalogs. 2021-02-02 17:11:55 -05:00
Catalog.pm Make eval statement naturally proof against perltidy 2022-09-12 11:59:43 +07:00
Makefile Allow granting SET and ALTER SYSTEM privileges on GUC parameters. 2022-04-06 13:24:33 -04:00
aclchk.c Fix come incorrect elog() messages in aclchk.c 2022-12-23 10:04:18 +09:00
catalog.c Revert 56-bit relfilenode change and follow-up commits. 2022-09-28 09:55:28 -04:00
dependency.c Static assertions cleanup 2022-12-15 10:10:32 +01:00
genbki.pl Pre-beta mechanical code beautification. 2022-05-12 15:17:30 -04:00
heap.c Avoid some overhead with open and close of catalog indexes 2022-11-16 10:49:05 +09:00
index.c Revert 56-bit relfilenode change and follow-up commits. 2022-09-28 09:55:28 -04:00
indexing.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
information_schema.sql Non-decimal integer literals 2022-12-14 06:17:07 +01:00
meson.build Add copyright notices to meson files 2022-12-20 07:54:39 -05:00
namespace.c Refactor aclcheck functions 2022-11-13 09:02:41 +01:00
objectaccess.c Pre-beta mechanical code beautification. 2022-05-12 15:17:30 -04:00
objectaddress.c Convert the reg* input functions to report (most) errors softly. 2022-12-27 12:26:01 -05:00
partition.c Add 'missing_ok' argument to build_attrmap_by_name 2022-11-29 09:39:36 +01:00
pg_aggregate.c Refactor aclcheck functions 2022-11-13 09:02:41 +01:00
pg_attrdef.c Fix typos. 2022-09-19 14:21:39 +05:30
pg_cast.c Record dependencies of a cast on other casts that it requires. 2022-10-17 14:02:05 -04:00
pg_class.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_collation.c Remove AssertArg and AssertState 2022-10-28 09:19:06 +02:00
pg_constraint.c Fix self-referencing foreign keys with partitioned tables 2022-10-07 19:37:48 +02:00
pg_conversion.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_db_role_setting.c Add USER SET parameter values for pg_db_role_setting 2022-12-09 13:12:20 +03:00
pg_depend.c Avoid using list_length() to test for empty list. 2022-08-17 11:12:35 -04:00
pg_enum.c Use multi-inserts for pg_enum 2022-11-16 12:41:29 +09:00
pg_inherits.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_largeobject.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_namespace.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_operator.c Fix long-obsolete comment. 2022-11-20 11:22:22 -05:00
pg_parameter_acl.c Split up guc.c for better build speed and ease of maintenance. 2022-09-13 11:11:45 -04:00
pg_proc.c Add USER SET parameter values for pg_db_role_setting 2022-12-09 13:12:20 +03:00
pg_publication.c Message style improvements 2022-09-24 18:41:25 -04:00
pg_range.c Update copyright for 2022 2022-01-07 19:04:57 -05:00
pg_shdepend.c Fix bug in DROP OWNED BY. 2022-09-28 10:42:07 -04:00
pg_subscription.c Move common catalog cache access routines to lsyscache.c 2022-08-02 10:47:22 +05:30
pg_type.c In extensions, don't replace objects not belonging to the extension. 2022-08-08 11:12:31 -04:00
sql_feature_packages.txt Cleanup in SQL features files 2020-03-28 08:46:18 +01:00
sql_features.txt Non-decimal integer literals 2022-12-14 06:17:07 +01:00
storage.c Revert 56-bit relfilenode change and follow-up commits. 2022-09-28 09:55:28 -04:00
system_functions.sql Replace SQLValueFunction by COERCE_SQL_SYNTAX 2022-11-21 18:31:59 +09:00
system_views.sql pgstat: Track time of the last scan of a relation 2022-10-14 11:11:34 -07:00
toasting.c Add UNIQUE null treatment option 2022-02-03 11:48:21 +01:00