Re: unsigned int4 - Mailing list pgsql-general

From Peter Eisentraut
Subject Re: unsigned int4
Date
Msg-id Pine.GSO.4.02A.10004041226260.6042-100000@Utter.DoCS.UU.SE
Whole thread Raw
In response to unsigned int4  (Scott M Jackson <scottmo@pnl.gov>)
List pgsql-general
On Mon, 3 Apr 2000, Scott M Jackson wrote:

> Is there a way to specify an unsigned int, such that it would create
> an ERROR condition if a transaction were to attempt to cause a
> particular value to go negative.

CREATE TABLE... (
  ...
  colname INTEGER CHECK (colname > 0)
  ...
);

--
Peter Eisentraut                  Sernanders väg 10:115
peter_e@gmx.net                   75262 Uppsala
http://yi.org/peter-e/            Sweden


pgsql-general by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: Create user prob.
Next
From: Peter Eisentraut
Date:
Subject: Re: The "nl" RPMs.