diff options
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/regress/expected/temp.out | 15 | ||||
| -rw-r--r-- | src/test/regress/sql/temp.sql | 11 |
2 files changed, 26 insertions, 0 deletions
diff --git a/src/test/regress/expected/temp.out b/src/test/regress/expected/temp.out index ad7d5581911..eab75dbe2c9 100644 --- a/src/test/regress/expected/temp.out +++ b/src/test/regress/expected/temp.out @@ -199,6 +199,21 @@ select pg_temp.whoami(); (1 row) drop table public.whereami; +-- types in temp schema +set search_path = pg_temp, public; +create domain pg_temp.nonempty as text check (value <> ''); +-- function-syntax invocation of types matches rules for functions +select nonempty(''); +ERROR: function nonempty(unknown) does not exist +LINE 1: select nonempty(''); + ^ +HINT: No function matches the given name and argument types. You might need to add explicit type casts. +select pg_temp.nonempty(''); +ERROR: value for domain nonempty violates check constraint "nonempty_check" +-- other syntax matches rules for tables +select ''::nonempty; +ERROR: value for domain nonempty violates check constraint "nonempty_check" +reset search_path; -- For partitioned temp tables, ON COMMIT actions ignore storage-less -- partitioned tables. begin; diff --git a/src/test/regress/sql/temp.sql b/src/test/regress/sql/temp.sql index e634ddb9ca4..761955bfe6b 100644 --- a/src/test/regress/sql/temp.sql +++ b/src/test/regress/sql/temp.sql @@ -152,6 +152,17 @@ select pg_temp.whoami(); drop table public.whereami; +-- types in temp schema +set search_path = pg_temp, public; +create domain pg_temp.nonempty as text check (value <> ''); +-- function-syntax invocation of types matches rules for functions +select nonempty(''); +select pg_temp.nonempty(''); +-- other syntax matches rules for tables +select ''::nonempty; + +reset search_path; + -- For partitioned temp tables, ON COMMIT actions ignore storage-less -- partitioned tables. begin; |
