File: v17-dem-lnk_identity2comm-dynamic.sql

package info (click to toggle)
gnumed-server 22.31-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 46,268 kB
  • sloc: sql: 1,217,633; python: 15,878; sh: 1,590; makefile: 20
file content (22 lines) | stat: -rw-r--r-- 832 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
-- ==============================================================
-- GNUmed database schema change script
--
-- License: GPL v2 or later
-- Author: karsten.hilbert@gmx.net
--
-- ==============================================================
\set ON_ERROR_STOP 1

-- --------------------------------------------------------------
comment on column dem.lnk_identity2comm.comment is 'a comment on this communications channel';

\unset ON_ERROR_STOP
alter table dem.lnk_identity2comm drop constraint d_l_i2comm_sane_comment cascade;
\set ON_ERROR_STOP 1

alter table dem.lnk_identity2comm
	add constraint d_l_i2comm_sane_comment
		check (gm.is_null_or_non_empty_string(comment) is True);

-- --------------------------------------------------------------
select gm.log_script_insertion('v17-dem-lnk_identity2comm-dynamic.sql', '17.0');