]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
psql: Fix \df tab completion for procedures
authorFujii Masao <fujii@postgresql.org>
Fri, 3 Jul 2026 04:50:51 +0000 (13:50 +0900)
committerFujii Masao <fujii@postgresql.org>
Fri, 3 Jul 2026 04:50:51 +0000 (13:50 +0900)
Commit fb421231daa extended \df to include procedures, but its tab
completion continued not to show procedures.

Update \df tab completion to include procedures as well.

Backpatch to all supported versions.

Author: Erik Wienhold <ewie@ewie.name>
Reviewed-by: Surya Poondla <suryapoondla4@gmail.com>
Reviewed-by: Fujii Masao <masao.fujii@gmail.com>
Discussion: https://postgr.es/m/10fbfdfe-80f6-4ef9-b8b3-f7be0eb53a50@ewie.name
Backpatch-through: 14

src/bin/psql/tab-complete.c

index 4f0416d6b300a0999fd7aadb8867dcc9edd1b148..2749841323f78c44ca605c8d1280a188cc3cc105 100644 (file)
@@ -4036,7 +4036,7 @@ psql_completion(const char *text, int start, int end)
        else if (TailMatchesCS("\\dew*"))
                COMPLETE_WITH_QUERY(Query_for_list_of_fdws);
        else if (TailMatchesCS("\\df*"))
-               COMPLETE_WITH_VERSIONED_SCHEMA_QUERY(Query_for_list_of_functions, NULL);
+               COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_routines, NULL);
        else if (HeadMatchesCS("\\df*"))
                COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_datatypes, NULL);