Re: BUG #15057: Issue with UNKNOW type when calling a PostgreSQL function from java code

Поиск
Список
Период
Сортировка
От Andrew Gierth
Тема Re: BUG #15057: Issue with UNKNOW type when calling a PostgreSQL function from java code
Дата
Msg-id 87sha9rs41.fsf@news-spur.riddles.org.uk
обсуждение исходный текст
Ответ на Re: BUG #15057: Issue with UNKNOW type when calling a PostgreSQL function from java code  (Praveen Kumar <praveenkumar52028@gmail.com>)
Ответы Re: BUG #15057: Issue with UNKNOW type when calling a PostgreSQL function from java code
Список pgsql-bugs
>>>>> "Praveen" == Praveen Kumar <praveenkumar52028@gmail.com> writes:

 Praveen> [image: Inline image 2]

In future please use text rather than screenshots, so that you can
include the complete list rather than just a small part.

 Praveen> While calling one of these DECODE functions from my existing
 Praveen> select query,I am seeing an error saying

 Praveen> decode(numeric,integer,unknown,unknow) is not available

Because you didn't include the complete list of function signatures in
your message, we're left with the fact that the ones you _did_ show all
start out with anyelement,anyelement. Since polymorphic function
resolution requires all "anyelement" matches to be of the _same_ type,
it's clear that none of these can match a call which has numeric,integer
as the first two parameters.

Even if you changed your second parameter to be numeric rather than
integer, you'd then be faced with the fact that the list of signatures
contains at least these:

 decode(anyelement,anyelement,bigint,bigint)
 decode(anyelement,anyelement,character,character)
 decode(anyelement,anyelement,date,date)

So how would postgres be able to tell, given an argument list with types
(numeric,numeric,unknown,unknown), which of these signatures to use?
Obviously it would be ambiguous.

-- 
Andrew (irc:RhodiumToad)


В списке pgsql-bugs по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: BUG #15057: Issue with UNKNOW type when calling a PostgreSQL function from java code
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: BUG #15026: Deadlock using GIST index