On Tue, 09 Jun 2009 08:24:01 -0700, Brandon Metcalf
<brandon@xxxxxxxxxxxxxxxxxx> wrote:
CREATE TABLE foo (
start DATE,
length VARCHAR(10),
);
I need to be able to get one value for each column at any given time.
CREATE UNIQUE INDEX u ON foo ((start IS NOT NULL));
You would just make sure you SELECT FROM foo WHERE start IS NOT NULL;
However, it doesn't prevent you from having 0 rows on the table.
--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general