pg_proc probin misuse
- From: James William Pye <pgsql(at)jwp(dot)name>
- To: Hackers <pgsql-hackers(at)postgresql(dot)org>
- Subject: pg_proc probin misuse
- Date: Fri, 26 May 2006 19:41:46 -0700
- Message-id: <20060527024146(dot)GA54336(at)lit(dot)jwp(dot)name>
Hi,
In PL/Py, I had the bright idea of storing bytecode in the probin field of the
function's pg_proc row. However, this idea has lately become rather dim as I
have recently rediscovered(thanks Adrian) that this breaks dumps; pg_dump outputs
a PL/Py function as "CREATE FUNCTION x() RETURNS y LANGUAGE python AS
'<bytecode>', '<source>'". Of course, when loading this, it fails:
'ERROR: only one AS item needed for language "python"'.
So is this "fix your broken PL" or "pg_dump should only be doing that for C
language functions"? I imagine the former, so if that is the case perhaps
the 'probin' column description at [1] should be reworded to ensure others don't
get the same bright idea(the "language specific" part in particular).
Ugh, even if it were the latter, I would still be breaking existing versions,
so I'm inclined to fix it regardless..
Have a good evening (afternoon, morning, etc :).
[1] http://www.postgresql.org/docs/8.1/static/catalog-pg-proc.html
[Yeah, I do see the clarification at the bottom of the page. :( ]
Home |
Main Index |
Thread Index