Search Postgresql Archives

Re: Add custom properties to a column's definition (pg_attribute)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Brooke Beacham wrote
> (without having to replicate/maintain a table of columns separately from
> the system catalog)

Just create the friggin' table and wrap whatever logic you want in a view
(or functions) so that you at least get usable results/defaults for any
columns you haven't added.  

Any solution you pick has the risk of becoming out-of-sync so tossing out
the best solution does more harm than good.

In terms of "group" columns you might just consider creating two tables that
have a one-to-one relationship to each other (or three, the base table and
then group A and group B tables).

A lot depends on the why and structure of your model but there is no
standard facility for custom column meta-data and though the comment
facility can be used for this I much prefer to leave that for human
consumption and have something more structured and easily customize-able for
meta-data.
 
David J.




--
View this message in context: http://postgresql.1045698.n5.nabble.com/Add-custom-properties-to-a-column-s-definition-pg-attribute-tp5786158p5786174.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux