Re: Function parameters change when update to 8.3

From: tuanhoanganh <hatuan05(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Function parameters change when update to 8.3
Date: 2008-02-22 06:47:34
Message-ID: c235f61d0802212247o5d3f2ad7n65fb3b9bf0f00a43@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 2/22/08, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> tuanhoanganh <hatuan05(at)gmail(dot)com> writes:
> > ... But when I dump database and restore to 8.3 this function change to
>
> > CREATE OR REPLACE FUNCTION post_ctpt1(ud_stt_rec(24))
>
> It works as expected for me. Please provide a *complete* test case,
> including the specific dump and reload procedures you are using.
>
> regards, tom lane
>
My ud_stt_rec domain
CREATE DOMAIN ud_stt_rec
AS character(20)
DEFAULT ''::bpchar;
ALTER DOMAIN ud_stt_rec OWNER TO postgres;

I write script in Query of pgAdminIII
CREATE OR REPLACE FUNCTION test(ud_stt_rec)
RETURNS void AS
$BODY$
BEGIN
RETURN;
END
$BODY$
LANGUAGE 'plpgsql' VOLATILE;
ALTER FUNCTION test(ud_stt_rec) OWNER TO postgres;

This script run well.
In functions, I have a new function test. But when I choose "CREATE
script" with function test the script change to

-- Function: test(ud_stt_rec(24))

-- DROP FUNCTION test(ud_stt_rec(24));

CREATE OR REPLACE FUNCTION test(ud_stt_rec(24))
RETURNS void AS
$BODY$
BEGIN
RETURN;
END
$BODY$
LANGUAGE 'plpgsql' VOLATILE
COST 100;
ALTER FUNCTION test(ud_stt_rec(24)) OWNER TO postgres;

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dean Gibson (DB Administrator) 2008-02-22 07:45:24 Re: client_encoding
Previous Message Tom Lane 2008-02-22 05:36:42 Re: Function parameters change when update to 8.3