Re: Backslashes in string literals

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: Backslashes in string literals
Дата
Msg-id 200602011650.k11GoiU23147@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: Backslashes in string literals  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Ответы Re: Backslashes in string literals  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Список pgsql-hackers
Kevin Grittner wrote:
> We found a bug in the code from my first patch.  Since it was a low
> frequency, non-destructive type of problem for us, I was able to take my
> time and look over the task a little more closely.  Attached is a patch
> which should come close to implementing the TODO.  In particular, it is
> now implemented as a configurable option, which can be set in the
> postgresql.conf file or at run time.  There are some remaining issues:
> 
> (1)  I couldn't figure out the best way to obtain a value for
> standard_conforming_strings in the psql version of the scanner.  For our
> needs, could just assume it is always on, so I left it that way. 
> Someone with a better handle on this issue can hopefully finish that
> part.  Alternatively, if you give me some direction, I might have time
> to generalize it.  As far as I can tell from some testing today,
> everything works fine issuing statements through a connection, but psql
> isn't settled down.

Sounds like you made great progress!

The proper way to do (1) is to call libpq's pqSaveParameterStatus() from
psql.  Take a look for psql's session_username().  It is called
everytime the prompt is printed if the username is required.  One great
feature of using pqSaveParameterStatus() is that it reads server packets
and keeps the tracked value updated for you without query overhead.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Cleaning up the INET/CIDR mess
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Some platform-specific MemSet research