Re: using copy to load odd characters

Поиск
Список
Период
Сортировка
От Johnson, Shaunn
Тема Re: using copy to load odd characters
Дата
Msg-id 73309C2FDD95D11192E60008C7B1D5BB05FED9D8@snt452.corp.bcbsm.com
обсуждение исходный текст
Ответ на using copy to load odd characters  ("Johnson, Shaunn" <SJohnson6@bcbsm.com>)
Ответы Re: using copy to load odd characters
Re: using copy to load odd characters
Re: using copy to load odd characters
Список pgsql-general

--thanks for the reply!

--i've tried your example and it
--doesn't work for me.

--i'm also interested in why it's doing
--that (the problem).  it seems that if the
--field is a null and the column size is
--char(1) or so, the load will fail.  in my
--case, the field is a char(2) - would that have
--an impact on the load?

--maybe this is a red herring ...

-X

-----Original Message-----
From: Peter Eisentraut
To: Johnson, Shaunn
Cc: 'pgsql-general@postgresql.org '
Sent: 10/7/03 6:17 AM
Subject: Re: [GENERAL] using copy to load odd characters

Johnson, Shaunn writes:

> I'm trying to load data from a text file that
> has an odd character in it (^@).  From what I
> could tell, it's a NULL character.  How can I
> load that into the database via the command line?

Depends on what data type the column is supposed to have.  Character
data
types cannot contain null bytes.  The type bytea can store arbitrary
binary data.  It requires you to escape null bytes so '\\000'.

--
Peter Eisentraut   peter_e@gmx.net

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

Предыдущее
От: Karsten Hilbert
Дата:
Сообщение: Re: Problems defining a primary key !!
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: Problems defining a primary key !!