Re: Problem displaying functions and views in 7.1b3

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Hiroshi Inoue <Inoue@tpf.co.jp>
Cc: teo@flex.ro, pgsql-bugs@postgresql.org
Date: 2001-02-08T04:39:51Z
Lists: pgsql-bugs
Hiroshi Inoue <Inoue@tpf.co.jp> writes:
> How about the following though the result is different from
> datlastsysoid ?

>   select max(oid) from pg_database where datname like 'template%';

Too lax --- suppose someone makes a database named 'template3' ?

Even if we restricted the pattern to 'template[01]', it would fail
if someone deleted and rebuilt template1, which is a supported operation
now.

If we want to do it in a backwards-compatible fashion in pgaccess,
I'd recommend trying the datlastsysoid approach and then the other
way if that fails.  I'm just wondering if anyone cares ...

			regards, tom lane