Hi all, I create a table with Primary Key with name "gid" and type SERIAL. I have a dubt on the SERIAL type: this data type is a INTEGER (int4) type, but the sequence that is automatically created with pgAdmin has BIGINTEGER output (MAXVALUE 9223372036854775807). This fact can cause a numeric overflow during the insert? Version Postgres 9.0.3. Thanks in advance, Domenico.
On Tue, Sep 27, 2011 at 5:16 AM, DFE <mimmopasticcio@gmail.com> wrote: > Hi all, > I create a table with Primary Key with name "gid" and type SERIAL. > I have a dubt on the SERIAL type: this data type is a INTEGER (int4) > type, but the sequence that is automatically created with pgAdmin has > BIGINTEGER output (MAXVALUE 9223372036854775807). > This fact can cause a numeric overflow during the insert? yup -- if you're really worried about this, use BIGSERIAL. you could in theory cap the sequence, but you'd just be trading one error for another. merlin
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера