Re: quote string exactly as it is

Поиск
Список
Период
Сортировка
От Bill Todd
Тема Re: quote string exactly as it is
Дата
Msg-id 4B171647.8090100@dbginc.com
обсуждение исходный текст
Ответ на quote string exactly as it is  ("dario.ber@libero.it" <dario.ber@libero.it>)
Список pgsql-general
My solution was to set standard_conforming_strings = on in postgresql.conf.

Bill

dario.ber@libero.it wrote:
> Hello,
>
> How can I quote a string *exactly* as it is? I tried using
> quote_literal() but it doesn't return what I need in some cases.
>
> E.g.
>
> If my
> string is: ss\\\ss
>
> And I do:
>
> select quote_literal('ss\\\ss');
>
> I get:
>
>
> E'ss\\ss'  <-- My string now has E'' added and one backslash has been removed!
>
>
> What I want to do is to pass a string to a custom made function. Since the
> string can contain various metacharcters I need some way to pass this string
> exactly as it is.
>
> (For those who might be interested, the strings I'm working
> with are FASTQ quality scores)
>
> I'm using Postgresql 8.3 on Windows XP
>
> Thanks
> a lot!
>
>
> Dario
>
>


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

Предыдущее
От: Tatsuo Ishii
Дата:
Сообщение: Re: Large Objects and Replication question
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Build universal binary on Mac OS X 10.6?