From: "Greg Sabino Mullane" on

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160


> Well, if you put information_schema in the default path, it'd be
>
> SELECT * FROM TABLES;

Except it also shows views[1]. Oh, and it has a bunch of other arcane
and unwanted columns. Which we can't remove, nor can we add additional
columns to it, because it was specified by the standard, which
means that it was designed by committee and thus ugly and unusable
for most things.

[1] Granted, it would at least *tell* you its a view, unlike
MySQL's SHOW TABLES. On the other hand, no owner as per \dt

P.S. What's with the uppercase mania in this thread? Can we
please get back to saying "select * from tables"
and "show tables"? :)

- --
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
-----BEGIN PGP SIGNATURE-----

iEYEAREDAAYFAkw/WA0ACgkQvJuQZxSWSsilEwCgqo8OefwS2B65JnJjH9xLVhp0
R2wAoPtuMxSPvVKfZ19yBDo8as59p7lv
=YmAb
-----END PGP SIGNATURE-----



--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Alvaro Herrera on
Excerpts from Peter Eisentraut's message of jue jul 15 14:21:26 -0400 2010:
> On tor, 2010-07-15 at 17:35 +0100, Simon Riggs wrote:
> > There should be one command to "display a list of tables" and it needs
> > to be easily guessable for those who have forgotten.
>
> Well, if you put information_schema in the default path, it'd be
>
> SELECT * FROM TABLES;

Or even

TABLE TABLES;

weird though that is ...

--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Robert Haas on
On Jul 15, 2010, at 11:59 AM, Simon Riggs <simon(a)2ndQuadrant.com> wrote:
> On Thu, 2010-07-15 at 18:43 +0200, Magnus Hagander wrote:
>> On Thu, Jul 15, 2010 at 18:35, Simon Riggs <simon(a)2ndquadrant.com> wrote:
>>> On Thu, 2010-07-15 at 17:38 +0200, Magnus Hagander wrote:
>>>
>>>> Is there an actual common use-case for having these commands available
>>>> for *non-psql* interfaces?
>>>
>>> There are many interfaces out there and people writing new ones
>>> everyday. We just wrote an interface for Android, for example.
>>>
>>> It is arguably *more* important to do this from non-psql interfaces.
>>>
>>> There should be one command to "display a list of tables" and it needs
>>> to be easily guessable for those who have forgotten.
>>
>> The downside is that you are then limited to what can be returned as a
>> resultset. A "\d table" in psql returns a hell of a lot more than
>> that. So do we keep two separate formats for this? Or do we remove the
>> current, useful, output format in favor of a much worse formt just to
>> support more clients?
>
> I imagined that we would do something similar to EXPLAIN, a set of text
> rows returned.

That seems rather wretched for machine-parsability, which I think is an important property for anything we do in this area. We need to think harder about how we could structure this to allow returning more than just a tabular result set while still allowing clients easy programmatic access to the underlying data.

> It should be possible to migrate \d options to using new outputs, when
> everything works in a useful manner. Probably not in this release.
>
> If I get some working solutions ready for Sept 15 we then have 4 months
> for other people to patch away at this.

Sounds good, but we need agreement on a more detailed design first.

....Robert
--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: Peter Eisentraut on
On tor, 2010-07-15 at 19:21 +0200, Andreas 'ads' Scherbaum wrote:
> Is there a way to query all databases from information_schema?

No.


--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

From: "Joshua D. Drake" on
On Thu, 2010-07-15 at 18:48 +0000, Greg Sabino Mullane wrote:

> P.S. What's with the uppercase mania in this thread? Can we
> please get back to saying "select * from tables"
> and "show tables"? :)

The standard specifies that it it should be uppercase.

:P

JD



--
PostgreSQL.org Major Contributor
Command Prompt, Inc: http://www.commandprompt.com/ - 509.416.6579
Consulting, Training, Support, Custom Development, Engineering


--
Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers