From: Kumar <sgnerd@yahoo.com.sg>
To: psql <pgsql-sql@postgresql.org>
Subject: Using % type in Parameters
Date: Tue, 28 Oct 2003 14:39:47 +0530
Message-ID: <030101c39d33$43cdce80$7502a8c0@hdsc.com> (raw)
Dear Friends,
Clarification about the support for the usage of % TYPE in Postgres. I am working with postgres 7.3.4 on RH Linux 7.2. Can I use the %TYPE in parameters as in Oracle.
CREATE OR REPLACE FUNCTION public.fn_listtitle(varchar, varchar)
RETURNS refcursor AS
'
DECLARE
ref REFCURSOR;
BEGIN
OPEN ref FOR
SELECT "Lookuptype", "Lookupname"
FROM "Lookups"
WHERE "Lookuptype" = $1 AND
"Lookup_ID " = $2;
END;
'
LANGUAGE 'plpgsql' VOLATILE;
Here can I use as
CREATE OR REPLACE FUNCTION public.fn_listtitle(%Lookups.Lookuptype, %Lookups.Lookup_ID)
Please shed some light.
Regards
Kumar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: sgnerd@yahoo.com.sg
Subject: Re: Using % type in Parameters
In-Reply-To: <030101c39d33$43cdce80$7502a8c0@hdsc.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox