Search Postgresql Archives

Re: Improvement for COPY command .. unless it already exists

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I want to default some columns for this COPY command only. So DEFAULT is not appropriate in this case. In fact I think you suggested a workaround right ? Doing an alter table before and another one after will work ... not fully clean thought since my user may not have the write to modify the table. Being able to specify default values directly in the COPY command will be really nice :-) I just wanted to share my tought :-)

Being eable to read zipped file will be cool to .. but I'm not sure it's Chrismas yet right so I didn't ask ;-)

Thanks for your help
/David

Tom Lane wrote:

David Gagnon <dgagnon@xxxxxxxxxx> writes:


Is there a way to specify default values in the COPY command?



There's always ALTER TABLE ... SET DEFAULT.

			regards, tom lane





---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
   (send "unregister YourEmailAddressHere" to majordomo@xxxxxxxxxxxxxx)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux