Project

General

Profile

« Previous | Next » 

Revision 12272

schemas/util.sql: added mk_set_search_path(VARIADIC schemas text[])

View differences:

util.sql
1744 1744

  
1745 1745

  
1746 1746
--
1747
-- Name: mk_set_search_path(text[]); Type: FUNCTION; Schema: util; Owner: -
1748
--
1749

  
1750
CREATE FUNCTION mk_set_search_path(VARIADIC schemas text[]) RETURNS text
1751
    LANGUAGE sql IMMUTABLE
1752
    AS $_$
1753
SELECT util.mk_set_search_path(util.mk_search_path(VARIADIC $1))
1754
$_$;
1755

  
1756

  
1757
--
1758
-- Name: FUNCTION mk_set_search_path(VARIADIC schemas text[]); Type: COMMENT; Schema: util; Owner: -
1759
--
1760

  
1761
COMMENT ON FUNCTION mk_set_search_path(VARIADIC schemas text[]) IS '
1762
usage:
1763
for *1* schema arg:
1764
SELECT util.mk_set_search_path(''schema'', NULL) AS search_path;
1765
	-- 2 params are needed to use the correct variant of mk_set_search_path()
1766
';
1767

  
1768

  
1769
--
1747 1770
-- Name: mk_set_search_path(text); Type: FUNCTION; Schema: util; Owner: -
1748 1771
--
1749 1772

  

Also available in: Unified diff