| От | Tom Lane |
|---|---|
| Тема | Re: Smallint needs explicit cast in psql? |
| Дата | |
| Msg-id | 13145.1342458230@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Smallint needs explicit cast in psql? (Matt Musgrove <MMusgrove@efji.com>) |
| Ответы |
Re: Smallint needs explicit cast in psql?
|
| Список | pgsql-novice |
Matt Musgrove <MMusgrove@efji.com> writes:
> Does psql require smallints to be explicitly cast as such?
Undecorated integer-looking constants are taken as integer, bigint, or
numeric depending on size. Not smallint. By and large it's best
not to use smallint as the declared argument type of a function unless
you really have to.
(We have looked into allowing small-enough literals to be taken as
smallint. Turns out to break a whole lot of stuff, by introducing
ambiguities where there were none before, so it's not likely
to ever happen.)
regards, tom lane
В списке pgsql-novice по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера