Project

General

Profile

« Previous | Next » 

Revision 14140

schemas/util.sql: added derived_col_defs()

View differences:

trunk/schemas/util.sql
1454 1454

  
1455 1455

  
1456 1456
--
1457
-- Name: derived_col_defs(regclass); Type: FUNCTION; Schema: util; Owner: -
1458
--
1459

  
1460
CREATE FUNCTION derived_col_defs(table_ regclass) RETURNS SETOF check_constraint_def
1461
    LANGUAGE sql IMMUTABLE
1462
    AS $_$
1463
SELECT constraint_ FROM util.check_constraint
1464
WHERE table_ = $1 AND name IN (SELECT * FROM util.col_names($1))
1465
$_$;
1466

  
1467

  
1468
--
1457 1469
-- Name: derived_cols(regclass, regclass); Type: FUNCTION; Schema: util; Owner: -
1458 1470
--
1459 1471

  

Also available in: Unified diff