Skip site navigation (1) Skip section navigation (2)

Proposal: new border setting in psql

From: "D'Arcy J(dot)M(dot) Cain" <darcy(at)druid(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Proposal: new border setting in psql
Date: 2008-08-21 15:57:19
Message-ID: 20080821115719.d0b83a7d.darcy@druid.net (view raw or flat)
Thread:
Lists: pgsql-hackers
Here is a simple select output.

darcy=# select title_id, title_name from title;
 title_id | title_name 
----------+------------
        2 | Mrs
        3 | Ms
        4 | Miss
(3 rows)

Now I change the border.

darcy=# \pset border 2
Border style is 2.
darcy=# select title_id, title_name from title;
+----------+------------+
| title_id | title_name |
+----------+------------+
|        2 | Mrs        |
|        3 | Ms         |
|        4 | Miss       |
+----------+------------+
(3 rows)

I would like to propose a new border setting.

darcy=# \pset border 3
Border style is 3.
darcy=# select title_id, title_name from title;
+----------+------------+
| title_id | title_name |
+==========+============+
|        2 | Mrs        |
+----------+------------+
|        3 | Ms         |
+----------+------------+
|        4 | Miss       |
+----------+------------+
(3 rows)

The reason for this is to allow the output to be fed directly into any
system using Restructured text as described in
http://docutils.sourceforge.net/docs/user/rst/quickref.html.

If there is any interest I will submit patches for code and
documentation.

-- 
D'Arcy J.M. Cain <darcy(at)druid(dot)net>         |  Democracy is three wolves
http://www.druid.net/darcy/                |  and a sheep voting on
+1 416 425 1212     (DoD#0082)    (eNTP)   |  what's for dinner.

Responses

pgsql-hackers by date

Next:From: Peter EisentrautDate: 2008-08-21 16:10:35
Subject: Re: A smaller default postgresql.conf
Previous:From: Tom LaneDate: 2008-08-21 14:15:36
Subject: Re: Questions about HeapTupleHeaderData

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group