Re: [INTERFACES] COPY syntax
| От | Eric Marsden |
|---|---|
| Тема | Re: [INTERFACES] COPY syntax |
| Дата | |
| Msg-id | m24svgsuk5.fsf@cook.onecert.fr обсуждение исходный текст |
| Ответ на | Re: [INTERFACES] '\' and varchar data type problem w/ MS Access a nd ODBC driver (Tom Lane <tgl@sss.pgh.pa.us>) |
| Ответы |
Re: [INTERFACES] COPY syntax
|
| Список | pgsql-interfaces |
>>>>> "TL" == Tom Lane <tgl@sss.pgh.pa.us> writes:
TL> COPY IN/OUT data needs to be handled slightly differently from
TL> data seen in SQL commands and SELECT results. In particular,
TL> COPY likes to represent null values as \N, which can be confused
TL> with a valid string value if you don't escape backslash.
I am struggling with this right at the moment (I'm new to databases,
I'm struggling with everything). Is it possible to use functions in
COPY input? Specifically, I am trying to do this
COPY attributes FROM 'home/ecm/prog/database/attributes.data';
where the file contains entries like (with tabs)
nextval('attribute_id_sequence') Control and Monitoring \N
I get an ERROR: pg_atoi: error in "nextval(attribute_id_sequence)":
can't parse "nextval(attribute_id_sequence)". Should I be using
auto-generated numbers and setting the sequence to an initial value
instead?
--
Eric Marsden
emarsden @ mail.dotcom.fr
It's elephants all the way down
В списке pgsql-interfaces по дате отправления: