----- Original Message ----- From: "Dave Page" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Monday, October 13, 2003 3:17 PM Subject: Re: [pgadmin-support] View column defaults in pgAdminIII
<snip> >> b) Include in the view definition DDL any column defaults. >> When I do a pg_dump -t myview... at the server console, the >> output includes not only the view DDL, rules, and >> permissions, but also column defaults. Would be nice for the >> sake of completeness to see the column defaults in the >> pgAdminIII DDL also. >I'm not sure what you mean here. Views don't have column defaults, only >the underlying relations do. How would you expect that to be expressed >in SQL (which pg_dump didn't do when I tried it btw)? >Regards, Dave. Sorry but I believe you are mistaken on this one. For example to set the default value of a column of a view you issue the command which is very similar to that of a table: Example: ALTER TABLE vu_someview ALTER COLUMN b_somecolumn SET DEFAULT '0'; Regards Donald Fraser. ---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faqs/FAQ.html