mismatching proargtypes/proallargtypes (bug #10122) - Mailing list pgsql-bugs

From Andres Freund
Subject mismatching proargtypes/proallargtypes (bug #10122)
Date
Msg-id 20140424002211.GD12442@awork2.anarazel.de
Whole thread Raw
Responses Re: mismatching proargtypes/proallargtypes (bug #10122)  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
Hi,

'trinque' on irc reported that "SELECT pg_catalog.pg_identify_object(oid,
integer, integer)'::regprocedure" doesn't work and Andrew Gierth noticed
it's because proargtypes doesn't match proallargtypes.

Surpringsly there's no regression check testing for that. I recall
running into problems with mismatches there myself in the past. The
attached patch fixes the two wrong cases and adds a regression test to
prevent further occurances.
The broken functions are:
 oid  |                 oid                 | proargtypes |     proallargtypes     | filtered_allargtypes |
proargmodes   

------+-------------------------------------+-------------+------------------------+----------------------+-----------------
 3078 | pg_sequence_parameters(oid)         | {26}        | {23,20,20,20,20,16}    | {23}                 |
{i,o,o,o,o,o}
 3839 | pg_identify_object(oid,oid,integer) | {26,26,23}  | {26,23,23,25,25,25,25} | {26,23,23}           |
{i,i,i,o,o,o,o}

sequence_parameters is wrong in 9.1+, identify_object in 9.3+.

Luckily neither is particularly important. It's really a pity that we
don't have infrastructure for fixing this like this :/.

Do we need a note in the release notes for fixing those functions?

I am sending this as a separate thread as the actual bugreport is
still stuck in moderation and I going to bed. Don't want somebody to
waste their time duplicating this.

Greetings,

Andres Freund

--
 Andres Freund                       http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

Attachment

pgsql-bugs by date:

Previous
From: John R Pierce
Date:
Subject: Re: BUG #10116: Unable to load more than 100 recs - trial version
Next
From: Tom Lane
Date:
Subject: Re: mismatching proargtypes/proallargtypes (bug #10122)