Create Function... ERROR: language "plpgsql" does not exist

From: "Thomas LeBlanc" <thomasatiem(at)hotmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Create Function... ERROR: language "plpgsql" does not exist
Date: 2003-10-13 15:58:55
Message-ID: Law9-F78SH3ZIrqTIov0000f92d@hotmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I copied an example from the help:

CREATE FUNCTION somefunc() RETURNS integer AS '
DECLARE
quantity integer := 30;
BEGIN
RAISE NOTICE ''Quantity here is %'', quantity; -- Quantity here is 30
quantity := 50;
--
-- Create a subblock
--
DECLARE
quantity integer := 80;
BEGIN
RAISE NOTICE ''Quantity here is %'', quantity; -- Quantity here is
80
END;

RAISE NOTICE ''Quantity here is %'', quantity; -- Quantity here is 50

RETURN quantity;
END;
' LANGUAGE plpgsql

Ran it is a SQL window from pgAdmin and got this error:

ERROR: language "plpgsql" does not exist

Thanks,
Thomas LeBlanc

_________________________________________________________________
Share your photos without swamping your Inbox. Get Hotmail Extra Storage
today! http://join.msn.com/?PAGE=features/es

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jan Wieck 2003-10-13 16:06:58 Re: more on undefined reference to 'pg_detoast_datum'
Previous Message Vivek Khera 2003-10-13 15:39:03 Re: go for a script! / ex: PostgreSQL vs. MySQL