This version contains one little change.
In order to be consistent with “\d+ viewname” it uses pg_get_viewdef(oid, /* pretty */ true) to produce “pretty” output
(withoutadditional parentheses).
> On 05 May 2015, at 16:42, Robert Haas <robertmhaas@gmail.com> wrote:
>
> On Mon, May 4, 2015 at 5:21 AM, Petr Korobeinikov
> <pkorobeinikov@gmail.com> wrote:
>> I'm proposing to add two new subcommands in psql:
>> 1. \ev viewname - edit view definition with external editor (like \ef for
>> function)
>> 2. \sv viewname - show view definition (like \sf for function, for
>> consistency)
>
> Sounds nice. Make sure to add your patch to the open CommitFest so we
> don't forget about it.
>
> https://commitfest.postgresql.org/action/commitfest_view/open
>
> --
> Robert Haas
> EnterpriseDB: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company