Re: BUG #6020: Wrong data type returned after CAST in FROM

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #6020: Wrong data type returned after CAST in FROM
Дата
Msg-id 1750.1305135610@sss.pgh.pa.us
обсуждение исходный текст
Ответ на BUG #6020: Wrong data type returned after CAST in FROM  ("Skylar Hawk" <skylar.j.hawk@gmail.com>)
Список pgsql-bugs
Skylar Hawk <skylar.j.hawk@gmail.com> writes:
> I got the similar results when I ran similar queries from a ruby
> script using the 'postgres' gem as well, which notified me of the
> difference through the error message. That's actually what alerted me
> to it first. The script calls a plpsql function which expects a
> CHAR(8) and the script died. The database message said the function
> was expecting a CHAR(8) but got a BPCHAR instead.

OK, now I'm really unsure what you're talking about.  There's no such
thing as a plpgsql function that "expects a char(8)" --- well, you can
declare it that way, but the database just ignores the length modifier.
And BPCHAR is just the internal name for CHAR(n), so it should certainly
have matched.

Could we see the *exact* function declaration, the exact SQL you issued,
and the exact error message, rather than ambiguous descriptions?

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: BUG #6020: Wrong data type returned after CAST in FROM
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #6020: Wrong data type returned after CAST in FROM