Re: repeated characters in SQL

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: repeated characters in SQL
Дата
Msg-id 15228.1453660870@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: repeated characters in SQL  (Francisco Olarte <folarte@peoplecall.com>)
Список pgsql-general
Francisco Olarte <folarte@peoplecall.com> writes:
> On Sun, Jan 24, 2016 at 7:05 PM,  <rashapoo@gmail.com> wrote:
>> I guess the escape character (which is not needed in, say, Notepad++) threw
>> me a bit.

> Notepad ++ is, AFAIK,  an editor, it SHOULD (within reason) let you
> write any text.

> The double quote is needed due to the quoting rules of the language.
> You want the regexp engine to see the characters leftp, dot, rightp,
> backslash, one. But backslah is the scape character in strings ( in
> many languages ), so you need to escape it too.

In this particular case, the extra backslash was needed only because
the OP used E'...' syntax for his string literal.  In a plain SQL
string literal, backslash isn't special.

            regards, tom lane


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

Предыдущее
От: Francisco Olarte
Дата:
Сообщение: Re: repeated characters in SQL
Следующее
От: "Regina Obe"
Дата:
Сообщение: Re: CoC [Final v2]