Re: backslash in psql win32

Поиск
Список
Период
Сортировка
От Martin Kanich
Тема Re: backslash in psql win32
Дата
Msg-id cahgne$t7c$1@sea.gmane.org
обсуждение исходный текст
Ответ на backslash in psql win32  (<Tom.Zschockelt@flender.com>)
Список pgsql-hackers-win32
Hi to all, specialy to Tom :-)

I have the same problem using backslash in mingw build of psql. the
reason for this "bug" is the use of readline
$POSTGRES_SOURCE\src\bin\psql\input.c

in function gets_interactive, if USE_READLINE defined the readline
function would be called:

#ifdef USE_READLINE
...
    if (useReadline)
       /* On some platforms, readline is declared as readline(char *) */
       s = readline((char *) prompt);
    else
       s = gets_basic(prompt);
...
#endif

if I set useReadline to false, it would use gets_basic and this works
with cmd & winxp & german settings (backslash using alt-gr). I don't
know what exactly happens in readline() and why it's better than
gets_basic(), but it shouldn't be used with msys/mingw.

Have a nice day,
Martin

Tom.Zschockelt@flender.com wrote:
>
> Hi to all,
>
>
> in win32 psql (startet from cmd.exe) it's not possible to execute any
> backslash command, because
> the backslash character does not appear . It's not possible to insert
> special characters !!!
>
> I changed the console charset to 850, 1252,
> but there is the same problem
>
> How can I solve this problem ?
>
> Regards
>
> tom
>
> hint : I use postgres-snapshot from 30.03.2004

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: pg_ctl start broken on windows
Следующее
От: Martin Kanich
Дата:
Сообщение: Installer