simple function syntax

From: Culley Harrelson <culleyharrelson(at)yahoo(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: simple function syntax
Date: 2001-01-26 05:55:56
Message-ID: 20010126055556.35043.qmail@web9603.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

OK trying to write my first function and its blowing
up at compile. What's wrong with this:

CREATE FUNCTION test_function(int4) RETURNS int4 AS '
DECLARE
test ALIAS FOR $1;
BEGIN
RETURN test;
END;
' LANGUAGE 'plpgsql';

__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - Buy the things you want at great prices.
http://auctions.yahoo.com/

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Robert B. Easter 2001-01-26 06:50:14 Re: simple function syntax
Previous Message Steve Leibel 2001-01-26 04:33:01 Re: Connection pooling