Re: View definition formatting

From: Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, Dave Page <dpage(at)vale-housing(dot)co(dot)uk>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: View definition formatting
Date: 2003-04-01 19:49:50
Message-ID: 1049226590.13853.2174.camel@camel
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers pgsql-hackers

On Tue, 2003-04-01 at 14:18, Tom Lane wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > Perhaps as a workaround you could invent a standard indentation format and
> > format the rules automatically that way, so that users will be able to
> > find everything in the same place automatically after the second edit
> > cycle.
>
> Perhaps we could make pg_get_ruledef and friends try to prettyprint
> their output a little better, instead of duplicating such logic in
> various clients (which couldn't do nearly as well at it anyway without
> re-parsing the string :-().
>
> Does anyone have code that depends on these functions returning
> single-line output? (I suppose the pg_rules and pg_views views might
> get a bit ugly, but perhaps psql could be taught to format data with
> embedded newlines better than it does now...)
>

Could we turn the prettyprint incantation into a user callable function?
We could easily add that to the phpPgAdmin code to call that function
when pulling information from pg_views.definition and it's ilk, this
giving a nicely formatted output without having to modify the way it is
currently stored.

Robert Treat

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Andreas Pflug 2003-04-01 19:54:05 Re: pgadmin3 query tools
Previous Message Tom Lane 2003-04-01 19:18:12 Re: View definition formatting

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2003-04-01 19:58:52 Re: View definition formatting
Previous Message Tom Lane 2003-04-01 19:18:12 Re: View definition formatting