Re: Create function problem

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Yaroslav Ulyanov" <yulyanov(at)mera(dot)ru>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: Create function problem
Date: 2003-09-04 13:55:54
Message-ID: 21879.1062683754@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

"Yaroslav Ulyanov" <yulyanov(at)mera(dot)ru> writes:

> CREATE FUNCTION "get_new_id1" () RETURNS bigint AS'
> declare
> id bigint;
> begin
> id:=3Dnextval(\'id_sequence\'::text);
> return id;
> end;
> 'LANGUAGE 'sql' VOLATILE ;

That's plpgsql code, but you've declared the function as language 'sql'.

regards, tom lane

In response to

Browse pgsql-interfaces by date

  From Date Subject
Next Message Bruce Momjian 2003-09-05 03:56:30 Re: ECPG Problem (Bug?)
Previous Message Michael Stephenson 2003-09-04 08:48:17 Re: pgAdmin