Re: can function arguments have the type tablename.columnname%TYPE?

From: Guillaume Lelarge <guillaume(at)lelarge(dot)info>
To: Igor Neyman <ineyman(at)perceptron(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Dino Vliet <dino_vliet(at)yahoo(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: can function arguments have the type tablename.columnname%TYPE?
Date: 2010-05-12 15:41:57
Message-ID: 4BEACC45.5020402@lelarge.info
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Le 12/05/2010 16:56, Igor Neyman a écrit :
> [...]
> I'm not sure why are you instisting that:
>
>> CREATE FUNCTION f1(arg1 table.column%TYPE ...
>>
>> Which, AFAICT, is not possible.
>
> It is definetily possible, i.e:
>
> CREATE OR REPLACE FUNCTION myMaxCycle(i_n_Cell_id GP_CELL.cell_id%TYPE)
> RETURNS GP_CYCLE.cycle_date_time%TYPE
> AS $$...
>
> Works in my 8.2 PG.
>

After looking in the manual, it seems you're right. Sorry about this.

--
Guillaume.
http://www.postgresqlfr.org
http://dalibo.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Richard Broersma 2010-05-12 15:45:15 Reliability of Windows versions 8.3 or 8.4
Previous Message Dave Page 2010-05-12 15:34:08 Re: Question about Beta for Windows 64 bits