Re: CSV From Oracle with timestamp column getting errors

Поиск
Список
Период
Сортировка
От Tim Cross
Тема Re: CSV From Oracle with timestamp column getting errors
Дата
Msg-id 87lfaeq4p0.fsf@gmail.com
обсуждение исходный текст
Ответ на CSV From Oracle with timestamp column getting errors  ("Saha, Sushanta K" <sushanta.saha@verizonwireless.com>)
Список pgsql-general
"Saha, Sushanta K" <sushanta.saha@verizonwireless.com> writes:

> \COPY table1 FROM '/tmp/Oracle_2020_06.csv' DELIMITER ',' CSV HEADER;
> ERROR:  invalid input syntax for type timestamp: "01-JUN-20 06.04.20.634000 AM"
> CONTEXT:  COPY table1, line 2, column last_update_timestamp: "01-JUN-20 06.04.20.634000 AM"
>

The problem is psql doesn't understand/recognise the timestamp format
being used in the CSV dump from Oracle.

Modify the SQL used to extract the data from Oracle so that it formats
the timestamp as a string which psql can parse into a timestamp type -
for example ISO or any of the psql timestamp formats (see psql manual). 

-- 
Tim Cross



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

Предыдущее
От: Victor Yegorov
Дата:
Сообщение: Re: CSV From Oracle with timestamp column getting errors
Следующее
От: Michael Schanne
Дата:
Сообщение: MultiXactId wraparound and last aggressive vacuum time