BUG #15071: Error in PostgreSQL-specific :: type cast

Поиск
Список
Период
Сортировка
От PG Bug reporting form
Тема BUG #15071: Error in PostgreSQL-specific :: type cast
Дата
Msg-id 151878227914.1391.18108972186680794975@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #15071: Error in PostgreSQL-specific :: type cast
Re: BUG #15071: Error in PostgreSQL-specific :: type cast
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      15071
Logged by:          Yuriy Beliy
Email address:      whiteman.kr@gmail.com
PostgreSQL version: 10.1
Operating system:   Windows 10
Description:

PostgreSQL-specific :: type casts for lowest values of integer types are
produce "Out of range" errors:

SELECT -32768::smallint
^ERROR:  smallint out of range

SELECT -2147483648::integer
^ERROR:  integer out of range

SELECT     -9223372036854775808::bigint
^ERROR:  bigint out of range

Standard-syntax type casts are workes correctly:

SELECT cast(-32768 as smallint)
^Ok

SELECT cast(-2147483648 as integer)
^Ok

SELECT     cast(-9223372036854775808 as bigint)
^Ok

For highest values (+32767, +2147483647, +9223372036854775807) - :: type
cast works correctly.




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

Предыдущее
От: PG Bug reporting form
Дата:
Сообщение: BUG #15070: description
Следующее
От: Daniel Gustafsson
Дата:
Сообщение: Re: BUG #15071: Error in PostgreSQL-specific :: type cast