Re: BUG #14251: COPY CSV: missing data for column that shouldn't be

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: BUG #14251: COPY CSV: missing data for column that shouldn't be
Дата
Msg-id 81b92ba9-0ef8-3b24-7c6c-6fca17c92655@hogranch.com
обсуждение исходный текст
Ответ на BUG #14251: COPY CSV: missing data for column that shouldn't be  (mickael.kerjean@gmail.com)
Список pgsql-bugs
On 7/14/2016 7:03 PM, mickael.kerjean@gmail.com wrote:
> "af,dekh"iykh'ya,Dekh"iykh'ya,13,,34.60345,69.2405"
> => The csv is valid but postgres doesn't really get it right

the quotes don't make much sense at all.

     country_code = "af
     city = dekh"iykh'ya
     city_accent = Dekh"iykh'ya
     region = 13
     population = NULL
     lat = 34.60345
     lng = 69.2405"



is dekh"iykh'ya  supposed to be accented characters or something?  If
you don't specify a QUOTE on your COPY command, it defaults to ", this
will definitely mess things up.   you might try specifying a QUOTE '%'
or something that doesn't exist in your data, I don't think you can
disable QUOTE entirely on CSV format copies.

--
john r pierce, recycling bits in santa cruz

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

Предыдущее
От: mickael.kerjean@gmail.com
Дата:
Сообщение: BUG #14251: COPY CSV: missing data for column that shouldn't be
Следующее
От: Noah Misch
Дата:
Сообщение: Re: BUG #14245: Segfault on weird to_tsquery