Received: from localhost (unknown [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 62C332E30F0 for ; Tue, 18 Dec 2007 12:58:39 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 03557-02-2 for ; Tue, 18 Dec 2007 12:58:36 -0400 (AST) Received: from starfish.geekisp.com (mail.geekisp.com [216.168.135.169]) by postgresql.org (Postfix) with ESMTP id 4EFD42E004C for ; Tue, 18 Dec 2007 12:58:36 -0400 (AST) Received: (qmail 30164 invoked by uid 1003); 18 Dec 2007 16:59:15 -0000 Received: from adsl-67-124-150-42.dsl.pltn13.pacbell.net (HELO dino-1.misuse.org) (public@misuse.org@67.124.150.42) by mail.geekisp.com with (DHE-RSA-AES256-SHA encrypted) SMTP; 18 Dec 2007 16:59:15 -0000 X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Date: Tue, 18 Dec 2007 08:53:15 -0800 To: pgsql-sql@postgresql.org From: Steve Midgley Subject: System catalog future changes Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Message-Id: <20071218165836.4EFD42E004C@postgresql.org> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200712/98 X-Sequence-Number: 29790 Hello again, Reading a previous recent post and answers called "Describe Table" got me thinking about a little piece of SQL I use in an application to get a list of all the tables for a specific namespace: select pg_class.relname as table_name from pg_class join pg_namespace on pg_namespace.oid = relnamespace where pg_class.relkind = 'r' and pg_namespace.nspname = 'public' order by pg_class.relname I have assumed that this sort of query would be relatively "durable" - that future system catalog changes are unlikely to make this query stop working? Does anyone have any knowledge of how "fixed" the columns and values of this query are (i.e. are there a lot of internal and external dependencies that make future Pg versiosn unlikely to break the above code)? Any other input on the above SQL - should I be doing this in another way? Thanks for any thoughts or advice, Steve