Re: order of statements in create function

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Markus Bertheau <twanger(at)bluetwanger(dot)de>, pgsql-general(at)postgresql(dot)org
Subject: Re: order of statements in create function
Date: 2004-07-09 18:46:38
Message-ID: 200407092046.38566.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Markus Bertheau wrote:
> why does everyone write
>
> CREATE FUNCTION foo() RETURNS INTEGER AS '
> blah blah
> ' LANGUAGE 'plpgsql';
>
> I've never seen for example:
>
> CREATE FUNCTION foo()
> RETURNS INTEGER
> LANGUAGE 'plpgsql'
> AS '
> blah blah
> ';
>
> Is there a special reason to this? I have a hard time believing that
> everyone does it the same way by coincidence.

The first used to be the only allowed order, before we made it more
flexible, as specified by the SQL standard.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Markus Bertheau 2004-07-09 19:02:51 Re: order of statements in create function
Previous Message Alvaro Herrera 2004-07-09 18:24:05 Re: order of statements in create function