Обсуждение: functions pg_get...
I'm looking for a postgres-funtion that shows me the definition of a table. I found the -- pg_catalog.pg_get_viewdef(oid) -- pg_catalog.pg_get_constraintdef(oid) -- pg_catalog.pg_get_triggerdef(oid) -- pg_get_indexdef(oid) but I miss the same for a relation. Monika König
On Thu, Nov 15, 2007 at 04:33:34PM +0100, "König, Monika" wrote: > I'm looking for a postgres-funtion that shows me the definition of a table. In psql, this is retrieved by \d [tablename]. By running psql -E, you'll be able to see how it generates that. (No, I'm not going to tell you, because I think it's good practice :) A -- Andrew Sullivan Old sigs will return after re-constitution of blue smoke
I've found the queries at this link to be very good for getting detailed postgresql schema information (table columns, triggers, etc)
-- Ilan
On Nov 15, 2007, at 10:33 AM, König, Monika wrote:
I'm looking for a postgres-funtion that shows me the definition of a table.I found the-- pg_catalog.pg_get_viewdef(oid)-- pg_catalog.pg_get_constraintdef(oid)-- pg_catalog.pg_get_triggerdef(oid)-- pg_get_indexdef(oid)but I miss the same for a relation.Monika König---------------------------(end of broadcast)---------------------------TIP 2: Don't 'kill -9' the postmaster
Ilan Volow
"Implicit code is inherently evil, and here's the reason why:"