Copy can't parse a float?

Поиск
Список
Период
Сортировка
От Dan Quaroni
Тема Copy can't parse a float?
Дата
Msg-id 9951857AC27D97449C62F7DD6C6122481D95A9@ponyexpress2.ad.openratings.com
обсуждение исходный текст
Ответы Re: Copy can't parse a float?  (Michael Fuhr <mike@fuhr.org>)
Список pgsql-novice

I'm trying to copy into a table from a file, and postgres is complaining about a float value.... The table is as follows:

smallint,
smallint,
int,
smallint,
smallint,
integer,
float8         

And the data file looks like:

2|11|30540|1|2||1.0
2|12|30540|1|1||0.0
2|13|30540|1|1||1.0
2|14|30540|1|1||1.0
2|15|30540|1|1||0.0

Here's my copy command:

echo "copy fact from '/data1/fact_oriZ01_2004.dat' with delimiter as '|' null as ''" | psql -d oridb

And it's dying on the first line with this error:

ERROR:  copy: line 1, pg_atoi: error in "1.0": can't parse ".0"

Why can't it parse .0 in a float8?

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

Предыдущее
От: Eduardo Vázquez Rodríguez
Дата:
Сообщение: Query optimization
Следующее
От: "A K"
Дата:
Сообщение: Bad Boolean external represenation *HELP*!