--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