allow referring to functions without arguments when unique

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: allow referring to functions without arguments when unique
Date: 2017-03-01 02:50:24
Message-ID: 932966cd-c089-087c-fa02-3ec83a523b67@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

This is the "grand finale" that goes on top of the "DROP FUNCTION of
multiple functions" patch set. The purpose is to allow referring to
functions without having to spell out the argument list, when the
function name is unique. This is especially useful when having to
operate on "business logic" functions with many many arguments. It's an
SQL standard feature, and it applies everywhere a function is referred
to in the grammar. We already have the lookup logic for the regproc
type, and thanks to the grand refactoring of the parser representation
of functions, this is quite a small patch. There is a bit of
reduce/reduce parser mystery, to keep the reviewer entertained. (The
equivalent could be implemented for aggregates and operators, but I
haven't done that here yet.)

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment Content-Type Size
0001-Allow-referring-to-functions-without-arguments-when-.patch text/x-patch 24.2 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2017-03-01 02:58:25 Re: port of INSTALL file generation to XSLT
Previous Message Peter Eisentraut 2017-03-01 02:35:01 Re: background sessions