change output of \dp

From: Euler Taveira de Oliveira <euler(at)ufgnet(dot)ufg(dot)br>
To: pgsql-patches(at)postgresql(dot)org
Subject: change output of \dp
Date: 2004-03-10 23:10:14
Message-ID: 20040310201014.2d47d080.euler@ufgnet.ufg.br
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

Hi,

I just noticed that \dp outputs "Table" to indicate relations (tables, sequences and views) instead of "Relation" or "Name". This patch just correct it, using "Name" and attaching its "Type".

Without the patch:

teste=# \d
List of relations
Schema | Name | Type | Owner
--------+--------+----------+-------
public | ab | sequence | euler
public | foo | table | euler
public | foobar | view | euler
public | teste | table | euler
(4 rows)

teste=# \dp
Access privileges for database "teste"
Schema | Table | Access privileges
--------+--------+---------------------------------------------
public | ab | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
public | foo | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
public | foobar |
public | teste | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
(4 rows)

And with the patch:

teste=# \dp
Access privileges for database "teste"
Schema | Name | Type | Access privileges
--------+--------+----------+---------------------------------------------
public | ab | sequence | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
public | foo | table | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
public | foobar | view |
public | teste | table | {euler=a*r*w*d*R*x*t*/euler,teste=ar/euler}
(4 rows)

Please apply it under HEAD, and if it's convenient, put it under 7_4 Branch.

Regards,

--
Euler Taveira de Oliveira
euler (at) ufgnet.ufg.br
Desenvolvedor Web e Administrador de Sistemas
UFGNet - Universidade Federal de Goiás

Attachment Content-Type Size
dp.patch application/octet-stream 1.2 KB

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Tatsuo Ishii 2004-03-11 01:49:53 Re: [PATCHES] NO WAIT ...
Previous Message Tom Lane 2004-03-10 23:08:25 Re: Defining a "tinyint" data type - one byte unsigned