--- Guy Fraser <[EMAIL PROTECTED]>

> If you have a 'serial' or 'bigserial' field like this :
> 
> create table test_table (
> test_id bigserial,
> data integer,
> comment text
> );
> 
> and you use :
> 
> copy test_table (data,comment) 
> from '/wherever/the/file/is' 
> using delimiters ',';
> 
> 
> to insert data like this :
> 
> 27,some kind of entry
> 32,another kind of entry
> 16,yet another entry
> ...
> 
> Assuming this is the first set of data entered the table will get populated
> with :
> 
>  1 | 27 | some kind of entry    
>  2 | 32 | another kind of entry 
>  3 | 16 | yet another entry     
> ...
> 
> I have used this in the past and it works well.

The problem I have is with COPY TO and not COPY FROM as I need to write a file.

Regards,
Clodoaldo

______________________________________________________________________

Yahoo! Messenger - Fale com seus amigos online. Instale agora! 
http://br.download.yahoo.com/messenger/

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faqs/FAQ.html

Reply via email to