Re: non-standard escapes in string literals

Поиск
Список
Период
Сортировка
От Lincoln Yeoh
Тема Re: non-standard escapes in string literals
Дата
Msg-id 5.1.0.14.1.20020603231833.02fc5490@192.228.128.13
обсуждение исходный текст
Ответ на Re: non-standard escapes in string literals  ("Zeugswetter Andreas SB SD" <ZeugswetterA@spardat.at>)
Ответы Re: non-standard escapes in string literals  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
At 01:20 PM 6/3/02 +0200, Zeugswetter Andreas SB SD wrote:
> > for two things, one for escaping single quotes and for escaping standard
> > C characters, like \n.  While we can use the standard-supported '' to
> > insert single quotes, what should we do with \n?  The problem is
> > switching to standard ANSI solution reduces our functionality.
>
>The problem imho is, that this (no doubt in many cases valuable)
>feature reduces the functionality from the ANSI SQL perspective.
>Consider a field that is supposed to store Windows filenames,
>nam_file='C:\node1\resend\b.dat' :-)
>
>Thus I think a GUC to turn off all escaping except '' would be valuable.

With current behaviour 'C:\node1\resend\b.dat' can be quoted as 
'C:\\node1\\resend\\b.dat'

But for the ANSI standard how does one stuff \r\n\t and other control 
characters into the database?

If there's no way other than actually sending the control characters then 
that is a bad idea especially from a security viewpoint.

Cheerio,
Link.



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Jason Tishler
Дата:
Сообщение: Re: HEADS UP: Win32/OS2/BeOS native ports
Следующее
От: Oleg Bartunov
Дата:
Сообщение: Re: GOODS - a sensational public domain database backend