Re: bulk loader

Поиск
Список
Период
Сортировка
От Brent Wood
Тема Re: bulk loader
Дата
Msg-id 20050520111403.U45363@storm-user.niwa.co.nz
обсуждение исходный текст
Ответ на bulk loader  (Hrishikesh Deshmukh <hdeshmuk@gmail.com>)
Список pgsql-general

On Thu, 19 May 2005, Hrishikesh Deshmukh wrote:

> Hi All,
>
> Is there a "bulk loader" in postgresql with which one can read in say
> a tab delimited format text file. Before one does all one has to do is
> create the table with text file column names as attributes, once it is
> on DBMS world it will be a simple table (non-relational)!!!!

See copy


from memory, pretty much as in:

cat <file> | \
  psql -d $DB -c "copy <table> from STDIN [with delimiter ','];"

You'll see that db users can't copy a file into a table but can copy
STDIN, so this approach works well.

Brent Wood

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

Предыдущее
От: "JC"
Дата:
Сообщение: problems with Win 2000
Следующее
От: Edmund Bacon
Дата:
Сообщение: Re: Count and Results together