Re: Standard metadata queries

From: Decibel! <decibel(at)decibel(dot)org>
To: Steve Atkins <steve(at)blighty(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Standard metadata queries
Date: 2008-04-25 03:28:49
Message-ID: 9E4305E9-BD0C-489A-A097-8D252207383B@decibel.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Apr 24, 2008, at 1:01 PM, Steve Atkins wrote:
> I've been chatting with the Trolltech folks about the
> implementation of the Qt wrapper around libpq, and the issue of how
> to properly do metadata queries came up. That is things like "What
> are the column names and types of the primary key of this table,
> and what index enforces it?" or "What are the names and types of
> each field of this table?".
>
> These seem like queries that'll be used by a lot of people, hidden
> down in ORMs and access libraries, and which are hard to get right,
> let alone efficient, and which will generally be written by one
> person (developing the ORM or library) and likely not touched again.
>
> Is there a standard set of well-crafted implementations of these
> anywhere that could be used by all the interface and ORM
> developers? If not, would it make sense to put some together and
> document or wiki them? Both as example code and as a set of good,
> solid queries that library developers can cut and paste.
>
> (The implementation I'm looking at right now has, amongst other
> things, hardwired OID-to-type mappings, and there's got to be a
> cleaner way than that).

Take a look at http://pgfoundry.org/projects/newsysviews/
--
Decibel!, aka Jim C. Nasby, Database Architect decibel(at)decibel(dot)org
Give your computer some brain candy! www.distributed.net Team #1828

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2008-04-25 03:40:22 Re: MERGE Specification
Previous Message Bruce Momjian 2008-04-25 03:27:03 Re: Proposed patch - psql wraps at window width