Re: psql eating backslashes

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: psql eating backslashes
Дата
Msg-id 4866.963870132@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: psql eating backslashes  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> But what should

> peter=# select 'abc\
> peter'# def';

> do? This doesn't seem right:

>  ?column?
> ----------
>  abc
> def
> (1 row)

Looks fine to me.

> Should the newline be stripped?

I would think not.  That would mean that backslash-newline gives you
something *other* than a literal newline, which is an inconsistency
we don't need since we don't treat newline as special.

Also, it would be changing the old (pre-7.0) behavior, which would
doubtless break someone's code somewhere.  In the absence of a
compelling reason to change the behavior, I think we have to leave it
alone.
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: TUPLE SIZE HELP
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Update: mac.c update, patch now on ftp