Re: [SQLObject] Dynamic features in CVS
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
From: Edmund L. <el...@in...> - 2003-03-31 19:04:45
|
On 03/31/2003 01:20:59 PM sqlobject-discuss-admin wrote: >my understanding is that >database introspection in Postgres is a lot harder than MySQL. I have >to figure out how to do tableExists in Postgres too... Not at all. Just rummage through the PostgreSQL system catalogs named pg_*. See http://www.postgresql.org/docs/view.php?version=7.3&idoc=0&file=catalogs.html For example, all relations are listed in pg_class. So, select relName, relkind from pg_class where relkind = 'r' gives you a list of all relations, including the system relations. ...Edmund. |