From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-sql@hub.org
Cc: pgsql-hackers@postgreSQL.org
Subject: Re: Number of parameters in a sql function
Date: Sat, 06 Mar 1999 12:20:49 -0500
Message-ID: <4179.920740849@sss.pgh.pa.us> (raw)
In-Reply-To: <199903060400.XAA05262@hub.org>
"Stan Ng" <stan@squaresoft.com> writes:
> I'm running into a limit problem with CREATE FUNCTION. Whenever I exceed
> the limit on parameters, somewhere around 12 for me, psql bombs on me
> with the "pqReadData() -- backend closed the channel unexpectedly" error
> message. Is there any way to increase the parameter limit for
> functions?
It shouldn't be letting you get that high; the system limit is 8
parameters for a function. (It looks to me like parse_func.c should
be, but is failing to, verify that the length of the parameter lists
it is passed are within bounds --- or else gram.y itself should complain
if the list is overlength.)
Increasing the limit would be rather a major project I suspect.
A quick look around the sources found a lot of dependencies, some
being symbolic constants (not all the same one :-() and some being
hard coded "8"s. Ick. Also, you would certainly be facing an initdb
and database reload, because the number of argument-type columns in
pg_proc would have to increase.
It'd be good to clean this up and replace pg_proc's fixed-size
proargtypes column with a variable-size "array of oid" column.
Any volunteers?
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, pgsql-sql@hub.org, pgsql-hackers@postgreSQL.org
Subject: Re: Number of parameters in a sql function
In-Reply-To: <4179.920740849@sss.pgh.pa.us>
References: <199903060400.XAA05262@hub.org> <4179.920740849@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox