psql: Add tab completion for DELETE ... USING.

This implements the tab completion that was marked as XXX TODO in the
source code. The following completion is now supported:

    DELETE FROM <table> USING <TAB> -> list of relations supporting SELECT

This uses Query_for_list_of_selectables (instead of Query_for_list_of_tables)
because the USING clause can reference not only tables but also views and
other selectable objects, following the same syntax as the FROM clause
of a SELECT statement.

Author: Tatsuya Kawata <[email protected]>
Reviewed-by: Chao Li <[email protected]>
Reviewed-by: Kirill Reshke <[email protected]>
Reviewed-by: Soumya S Murali <[email protected]>
Reviewed-by: Fujii Masao <[email protected]>
Discussion: 
https://postgr.es/m/cahza6qf0cljujr+5cqw0ownebm5vymb-ghokbgnejoq_jta...@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/0bf7d4ca9a6d0cd151de0209fd43671f158c1c88

Modified Files
--------------
src/bin/psql/tab-complete.in.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

Reply via email to