Project

General

Profile

« Previous | Next » 

Revision 8151

schemas/functions.sql: Added col_names(regclass), which unlike col_names(regtype) returns names in the order they are in the table

View differences:

schemas/functions.sql
560 560

  
561 561

  
562 562
--
563
-- Name: col_names(regclass); Type: FUNCTION; Schema: functions; Owner: -
564
--
565

  
566
CREATE FUNCTION col_names(table_ regclass) RETURNS SETOF text
567
    LANGUAGE sql STABLE STRICT
568
    AS $_$
569
SELECT attname::text
570
FROM pg_attribute
571
WHERE attrelid = $1 AND attnum >= 1
572
ORDER BY attnum
573
$_$;
574

  
575

  
576
--
563 577
-- Name: col_type(col_ref); Type: FUNCTION; Schema: functions; Owner: -
564 578
--
565 579

  

Also available in: Unified diff