Re: Copy function syntax on 8.1 - Mailing list pgsql-novice

From Mike G.
Subject Re: Copy function syntax on 8.1
Date
Msg-id 20050830172522.GA10003@localhost.localdomain
Whole thread Raw
In response to Re: Copy function syntax on 8.1  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Copy function syntax on 8.1
List pgsql-novice
On the non windows platforms you can issue the copy statement and the file path syntax is exactly the same as if you
werechanging directories in a shell.  No special escaping or syntax is needed. 

It would be nice if the same could be done for those forced to use windows.

In this case one does not really have a choice on whether or not they want to use special backslash processing.

I have no problem using the E'' if it will be supported well into the future.  It just is not as convenient.

Mike

On Tue, Aug 30, 2005 at 12:39:48PM -0400, Tom Lane wrote:
> "Mike G." <mike@thegodshalls.com> writes:
> > In testing 8.1 I turned on the escape_string_warning.  Now when I issue a COPY FROM / TO 'C:\\test' I am getting
the"non standard.." warning since file paths in Windows use the \ character.  I can clear the warning by changing the
syntaxto E'C:\\test'.   
>
> > Is their a way to properly escape the \ without using E or will the COPY function have to modified internally to
notreturn a warning if a \ is passed in the file path? 
>
> Why do you think COPY should be modified?  This is exactly the case that
> the warning is intended to warn about.
>
>             regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: if posting/reading through Usenet, please send an appropriate
>        subscribe-nomail command to majordomo@postgresql.org so that your
>        message can get through to the mailing list cleanly

pgsql-novice by date:

Previous
From: Tom Lane
Date:
Subject: Re: Copy function syntax on 8.1
Next
From:
Date:
Subject: New PGSQL and Linux Setup on Old Box