camper/deploy/nonnegative_integer.sql
jordi fita mas af31daba8a Add positive_integer and nonnegative_integer domains
This is easier to read and requires less unit tests, but i only used
them in the new relations and fields for HEAD, because i do not see any
point on creating migrations just for that.
2024-02-13 22:12:30 +01:00

15 lines
278 B
PL/PgSQL

-- Deploy camper:nonnegative_integer to pg
-- requires: schema_camper
begin;
set search_path to camper, public;
create domain nonnegative_integer as integer
check (value >= 0)
;
comment on domain nonnegative_integer is 'an integer that is either zero or positive';
commit;