.psqlrc version dependence (was Re: about EDITOR_LINENUMBER_SWITCH)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема .psqlrc version dependence (was Re: about EDITOR_LINENUMBER_SWITCH)
Дата
Msg-id 12759.1318692736@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: about EDITOR_LINENUMBER_SWITCH  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: .psqlrc version dependence (was Re: about EDITOR_LINENUMBER_SWITCH)
Список pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> Contrary to what the subject suggests, I think the main reason people
> wanted this feature was to be able to set the linestyle to unicode
> without getting a warning from older releases about unknown linestyle or
> something.  But in a few years, they'll have to
> maintain .psqlrc-9.2, .psqlrc-9.3, .psqlrc-9.4, etc.  That doesn't sound
> like a useful long-term solution either.

Well, "in a few years" they won't need that conditionality any more at
all, so I'm not sure I believe the above argument.  The problem seems
inherently self-limiting.

What struck me while looking at the patch is that it is conditional
based on *psql's* version.  Not the version of the server you're
connected to.  I'm not too sure what use-cases people have for version
dependence here, but I'd think that the server version would enter into
it sometimes.

(Of course, for server version to be used usefully, you'd need to
re-execute the rc file during \c, something we don't do now.)
        regards, tom lane


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

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: pg_dump vs malloc
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: .psqlrc version dependence (was Re: about EDITOR_LINENUMBER_SWITCH)