Re: [HACKERS] patches for items from TODO list

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] patches for items from TODO list
Дата
Msg-id 28122.1117307086@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] patches for items from TODO list  (Bruce Momjian <pgman@candle.pha.pa.us>)
Ответы Re: [HACKERS] patches for items from TODO list
Re: [HACKERS] patches for items from TODO list
Список pgsql-patches
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Here is an updated version of the COPY \x patch.  It is the first patch
> attached.
> Also, I realized that if we support \x in COPY, we should also support
> \x in strings to the backend.  This is the second patch.

Do we really want to do any of these things?  We've been getting beaten
up recently about the fact that we have non-SQL-spec string escapes
(ie, all the backslash stuff) so I'm a bit dubious about adding more,
especially when there's little if any demand for it.

I don't object too much to the COPY addition, since that's outside any
spec anyway, but I do think we ought to think twice about adding this
to SQL literal handling.

> Third, I found out that psql has some unusual handling of escaped
> numbers.  Instead of using \ddd as octal, it has \ddd is decimal, \0ddd
> is octal, and \0xddd is decimal.  It is basically following the strtol()
> rules for an escaped value.  This seems confusing and contradicts how
> the rest of our system works.

I agree, that's just going to confuse people.

> ! xqescape        [\\][^0-7x]

If you are going to insist on this, at least make it case-insensitive.

            regards, tom lane

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] patches for items from TODO list
Следующее
От: Michael Paesold
Дата:
Сообщение: Re: [HACKERS] patches for items from TODO list