PGSQL_Record1.htm
Invoke Query Tool: Select and click on Tool Menu and then click on Query Tool as shown Below:

 

CREATE OR REPLACE FUNCTION pgsql_record1
(OUT i int, OUT t text)
RETURNS SETOF RECORD AS $$
values (1,'integer'),(2,'text')
$$ LANGUAGE SQL;

save the script :

Note the  function pgsql_record1 , added under the current db/schema

Script Generated:

-- Function: pgsql_record1()

-- DROP FUNCTION pgsql_record1();

CREATE OR REPLACE FUNCTION pgsql_record1(OUT i integer, OUT t text)
RETURNS SETOF record AS
$BODY$
values (1,'integer'),(2,'text')
$BODY$
LANGUAGE sql VOLATILE
COST 100
ROWS 1000;
ALTER FUNCTION pgsql_record1()
OWNER TO postgres;

Now call This function from another SQL-Query Window.

From PHP query TOOL