mirror of
https://github.com/postgres/postgres.git
synced 2025-11-07 19:06:32 +03:00
Allow psql's \df and \do commands to specify argument types.
When dealing with overloaded function or operator names, having to look through a long list of matches is tedious. Let's extend these commands to allow specification of (input) argument types to let such results be trimmed down. Each additional argument is treated the same as the pattern argument of \dT and matched against the appropriate argument's type name. While at it, fix \dT (and these new options) to recognize the usual notation of "foo[]" for "the array type over foo", and to handle the special abbreviations allowed by the backend grammar, such as "int" for "integer". Greg Sabino Mullane, revised rather significantly by me Discussion: https://postgr.es/m/CAKAnmmLF9Hhu02N+s7uAyLc5J1xZReg72HQUoiKhNiJV3_jACQ@mail.gmail.com
This commit is contained in:
@@ -1229,6 +1229,19 @@ drop role regress_partitioning_role;
|
||||
\dAp+ btree float_ops
|
||||
\dAp * pg_catalog.uuid_ops
|
||||
|
||||
-- check \df, \do with argument specifications
|
||||
\df *sqrt
|
||||
\df *sqrt num*
|
||||
\df int*pl
|
||||
\df int*pl int4
|
||||
\df int*pl * pg_catalog.int8
|
||||
\df acl* aclitem[]
|
||||
\df has_database_privilege oid text
|
||||
\df has_database_privilege oid text -
|
||||
\dfa bit* small*
|
||||
\do - pg_catalog.int4
|
||||
\do && anyarray *
|
||||
|
||||
--
|
||||
-- combined queries
|
||||
--
|
||||
|
||||
Reference in New Issue
Block a user