Re: Escape handling in COPY, strings, psql

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: Escape handling in COPY, strings, psql
Дата
Msg-id 200505301126.45046.peter_e@gmx.net
обсуждение исходный текст
Ответ на Re: Escape handling in COPY, strings, psql  (Bruce Momjian <pgman@candle.pha.pa.us>)
Ответы Re: Escape handling in COPY, strings, psql  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
Bruce Momjian wrote:
> I was suggesting ESCAPE 'string' or ESC 'string'.  The marker has to
> be before the string so scan.l can alter its processing of the string
> --- after the string is too late --- there is no way to undo any
> escaping that has happened, and it might already be used by gram.y.

That pretty much corresponds to my E'string' proposal.  Both are 
probably equally trivial to implement.

> I agree with Tom that COPY has to be left unchanged.  The fundamental
> problem is the representation of NULL values, that I don't think we
> can do without some escape mechanism.  Single-quote escapes works by
> doubling them, but once you need to represent something more like
> null's, I can't think of a solution without escapes.

Yes, I now realize that COPY has a whole set of different rules anyway, 
so we can leave that out of this discussion.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/


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

Предыдущее
От: Hannu Krosing
Дата:
Сообщение: Re: compiling postgres with Visual Age compiler on
Следующее
От: Hannu Krosing
Дата:
Сообщение: Re: compiling postgres with Visual Age compiler on