Re: Bug with int2
От | Feng Tian |
---|---|
Тема | Re: Bug with int2 |
Дата | |
Msg-id | CAFWGqnuCTPbVmFciBGCRc15HQZf3_pNXGrQhUg8hTR5E469W=A@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Bug with int2 (Peter Geoghegan <pg@heroku.com>) |
Список | pgsql-hackers |
<div dir="ltr">Ah, thanks!</div><div class="gmail_extra"><br /><div class="gmail_quote">On Tue, Feb 16, 2016 at 7:54 PM,Peter Geoghegan <span dir="ltr"><<a href="mailto:pg@heroku.com" target="_blank">pg@heroku.com</a>></span> wrote:<br/><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">OnTue, Feb 16, 2016 at 7:27 PM, Feng Tian <<a href="mailto:ftian@vitessedata.com">ftian@vitessedata.com</a>>wrote:<br /> > I run into the following. Seems thisis a bug for -32768, which should be<br /> > a valid smallint value.<br /><br /></span>This isn't a bug. You see theerror only due to operator precedence:<br /><br /> postgres=# select (-32768)::int2;<br /> int2<br /> ─────────<br /> -32,768<br /> (1 row)<br /><span class="HOEnZb"><font color="#888888"><br /> --<br /> Peter Geoghegan<br /></font></span></blockquote></div><br/></div>
В списке pgsql-hackers по дате отправления: