Michael Fuhr <[EMAIL PROTECTED]> writes:
> On Sun, Apr 16, 2006 at 07:07:11PM +0300, [EMAIL PROTECTED] wrote:
>> I am interested to know if I can define an unique index on a timestamp
>> column to reject values within one hour.
Perhaps
CREATE UNIQUE INDEX foo ON tab (date_trunc('hour', co
On Sun, Apr 16, 2006 at 07:07:11PM +0300, [EMAIL PROTECTED] wrote:
> I am interested to know if I can define an unique index on a timestamp
> column to reject values within one hour.
Last month I posted an idea for enforcing unique constraints on
date ranges by using a composite type and a custom
hello,
I am interested to know if I can define an unique index on a timestamp
column to reject values within one hour.
insert into table(timestamp_col) values(LOCALTIMESTAMP);
insert into table(timestamp_col) values(LOCALTIMESTAMP + '5
minutes'::INTERVAL);
I want the second insert to fail w