Re: How to add month.year column validation

From: Andy Shellam <andy-lists(at)networkmail(dot)eu>
To: Andrus <kobruleht2(at)hot(dot)ee>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: How to add month.year column validation
Date: 2009-12-22 20:10:42
Message-ID: C468E3EE-6B45-4092-BED3-4391FA4E9C96@networkmail.eu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi Andrus,

>
> How to add column validation to table column which forces this ?

You're looking for a constraint - I presume you know what conditions you want to check for - I've done a similar thing recently ensuring the first character in a column is a decimal point, or that if one column's value is something, another column's value is within a certain range etc.

http://www.postgresql.org/docs/8.4/static/ddl-constraints.html (assuming you're running 8.4)

Regards,
Andy

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Francisco Reyes 2009-12-22 20:10:55 Re: Not finding RPMs for 8.4.2!
Previous Message Francisco Reyes 2009-12-22 20:09:46 Re: Not finding RPMs for 8.4.2!