Re: Importing directly from BCP files
От | Tim Uckun |
---|---|
Тема | Re: Importing directly from BCP files |
Дата | |
Msg-id | CAGuHJrM1xMagmX0Lgwv2BymSegyix7CdXqf82Pw0Dk3W0B6o3Q@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Importing directly from BCP files (David Rowley <david.rowley@2ndquadrant.com>) |
Ответы |
Re: Importing directly from BCP files
|
Список | pgsql-general |
I have the format files so that's good.
Have you tried opening a file in a text editor to see what they look like?
Yes. It looks like a binary file with lots of non printable characters. I tried running it through iconv with common encodings (windows-1524, utf-16, utf-32 and few others) but I can't seem to get a clean UTF-8 or ASCII conversion for some reason.
The bulk import command in PostgreSQL is COPY, so you'll likely want to look at http://www.postgresql.org/docs/9.4/static/sql-copy.html
I need to get them into a shape where copy command can process them first I think.
Has anybody done anything like this before?I'd imagine that it's fairly common.
I googled for quite a while and couldn't find anything. Unfortunately the -f "format" option makes it hard to search for "BCP file format" or something similar.
В списке pgsql-general по дате отправления: