Project

General

Profile

« Previous | Next » 

Revision 12387

schemas/vegbien.sql: added validatable_datasources()

View differences:

vegbien.sql
2294 2294

  
2295 2295

  
2296 2296
--
2297
-- Name: validatable_datasources(anyelement); Type: FUNCTION; Schema: public_validations; Owner: -
2298
--
2299

  
2300
CREATE FUNCTION validatable_datasources(schema_anchor anyelement DEFAULT NULL::schema_anchor) RETURNS SETOF text
2301
    LANGUAGE plpgsql
2302
    AS $$
2303
/* must use LANGUAGE plpgsql because LANGUAGE sql does not support runtime
2304
changes of search_path (schema elements are bound at inline time rather than
2305
runtime) */
2306
/* function option search_path is needed to limit the effects of
2307
`SET LOCAL search_path` (mk_set_search_path()) to the current function */
2308
BEGIN
2309
	EXECUTE util.mk_use_own_schema(schema_anchor);
2310
	
2311
	RETURN QUERY
2312
		SELECT DISTINCT util.schema(view) FROM validation_views() view;
2313
END;
2314
$$;
2315

  
2316

  
2317
--
2297 2318
-- Name: validation_views(text); Type: FUNCTION; Schema: public_validations; Owner: -
2298 2319
--
2299 2320

  

Also available in: Unified diff