Re: TODO item -- Improve psql's handling of multi-line - Mailing list pgsql-patches

From Tom Lane
Subject Re: TODO item -- Improve psql's handling of multi-line
Date
Msg-id 7307.1134023694@sss.pgh.pa.us
Whole thread Raw
In response to Re: TODO item -- Improve psql's handling of multi-line  ("Sergey E. Koposov" <math@sai.msu.ru>)
Responses Re: TODO item -- Improve psql's handling of multi-line  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-patches
"Sergey E. Koposov" <math@sai.msu.ru> writes:
> On Wed, 7 Dec 2005, Andrew Dunstan wrote:
>> A zero byte is probably a pretty bad choice. Some other low valued byte
>> (e.g. \x01 ) would probably work better.

> Currently I replace '\n' with the '\x01' as Andrew suggested.

Won't this get confused by some of the Far Eastern encodings we support?
The zero-byte approach is at least proof against that.  But what we need
to ask is whether we can expect readline to cope with either.

The patch *looks* pretty ugly: random insertions of blank space,
general failure to conform to the project's code layout conventions,
etc.  (Some of this would get cleaned up by pgindent, but I'm not sure
how much.)  Also I get the impression that the patch enforces a lot of
history maintenance overhead even in the non-USE_READLINE case, which is
surely useless.

            regards, tom lane

pgsql-patches by date:

Previous
From: "Sergey E. Koposov"
Date:
Subject: Re: TODO item -- Improve psql's handling of multi-line
Next
From: Dmitry Karasik
Date:
Subject: implement prepared queries in plperl