Re: "invalid input syntax for integer" for number with exponent

Поиск
Список
Период
Сортировка
От Bzzzz
Тема Re: "invalid input syntax for integer" for number with exponent
Дата
Msg-id 20180228222420.069510a6@msi.defcon1
обсуждение исходный текст
Ответ на "invalid input syntax for integer" for number with exponent  (Stephen Froehlich <s.froehlich@cablelabs.com>)
Ответы Re: "invalid input syntax for integer" for number with exponent  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-novice
On Wed, 28 Feb 2018 21:16:37 +0000
Stephen Froehlich <s.froehlich@cablelabs.com> wrote:

> I'm getting the following error when trying to go from R to a bigint
> field in PostgreSQL.
> 
> COPY invalid input syntax for integer: "1.12589990684262e+015"
> 
> Do I need to convert the number into text manually in R?  Exactly what
> about this input is confusing PostgreSQL?

Take a closer look at this number: is it a FLOAT, not an integer, thus
you get an error trying to insert a float in an integer column.

JY


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

Предыдущее
От: Stephen Froehlich
Дата:
Сообщение: "invalid input syntax for integer" for number with exponent
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: "invalid input syntax for integer" for number with exponent