Re: Proposal: new border setting in psql

From: "Asko Oja" <ascoja(at)gmail(dot)com>
To: "D'Arcy J(dot)M(dot) Cain" <darcy(at)druid(dot)net>
Cc: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Proposal: new border setting in psql
Date: 2008-08-21 20:22:28
Message-ID: ecd779860808211322g70860e1fof11c4191a999d83c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Proposed formats don't look easier to read for humans.
I doubt that they are more common or easier to process by machines than just
COPY query TO STDOUT CSV;

> The reason for this is to allow the output to be fed directly into any
> system using Restructured text

The idea would be to use psql as backend for some other system?
Or what do you mean by fed directly?

On Thu, Aug 21, 2008 at 10:54 PM, D'Arcy J.M. Cain <darcy(at)druid(dot)net> wrote:

> On Thu, 21 Aug 2008 15:03:23 -0400
> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> > "D'Arcy J.M. Cain" <darcy(at)druid(dot)net> writes:
> > > I would like to propose a new border setting.
> >
> > That code is horrendously overcomplicated and unreadable already :-(
> > I'm not too eager to add more variants to it.
>
> Actually, I already made the code changes and they were surprisingly
> simple.
>
> > > 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.
> >
> > Is that *really* going to work? What about quoting/escaping
> > conventions?
>
> ReST is pretty good with that stuff.
>
> > Also, how many of those "any systems" actually exist? Markup
> > conventions are a dime a dozen.
>
> That I can't say. My impression was that it was reasonably well
> known. However, while ReST was *my* reason for proposing this it was
> also important to me that the format stand by itself. I think it
> does. It also follows the documentation in that it is an extension to
> border 2 but with more borders, just like border 2 is more than border
> 1, etc. It's a consistent progression.
>
> > On the whole I think it ought to be sufficient to support XML output
> > for people who want easily-machine-readable query output.
>
> Perhaps. The problem is that it still means running it through an
> external program. That's fine for scripted processes but not for ad
> hoc queries.
>
> Perhaps what we really need is the ability for users to install their
> own formatting functions. After all, we can define everything else.
>
> --
> 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.
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2008-08-21 20:26:35 Re: [HACKERS] [FINALLY] the TODO list has migrated to Wiki
Previous Message Alvaro Herrera 2008-08-21 20:15:51 Re: [FINALLY] the TODO list has migrated to Wiki