Project

General

Profile

« Previous | Next » 

Revision 12438

schemas/util.sql: added typeof(), which unlike pg_typeof() uses util.qual_name() to create a search_path-independent name

View differences:

util.sql
3334 3334

  
3335 3335

  
3336 3336
--
3337
-- Name: typeof(anyelement); Type: FUNCTION; Schema: util; Owner: -
3338
--
3339

  
3340
CREATE FUNCTION typeof(value anyelement) RETURNS text
3341
    LANGUAGE sql IMMUTABLE
3342
    AS $_$
3343
SELECT util.qual_name(pg_typeof($1))
3344
$_$;
3345

  
3346

  
3347
--
3337 3348
-- Name: typeof(text, regtype); Type: FUNCTION; Schema: util; Owner: -
3338 3349
--
3339 3350

  

Also available in: Unified diff