pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-admin@postgresql.org
Subject: Re: Should clients abort in case of server version mismatch ? [ subject modf: as they already warn ]
Date: Fri, 8 Dec 2006 21:16:54 +0530
Message-ID: <a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com> (raw)

On 12/8/06, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> "Rajesh Kumar Mallah" <mallah.rajesh@gmail.com> writes:
> > IMHO for major version mismatch psql should not present the
> > user with a prompt at all as certain commands are most likely
> > not work.
>
> The analogy you're drawing with pg_dump is faulty.  There are at least
> three good reasons for psql to be more forgiving of version mismatches
> than pg_dump is:

Overall there was no damage at all.

>
> 1. pg_dump is commonly run noninteractively (eg, from a cron job) where
> any mere warning will likely go unnoticed.  So it has to raise a hard
> error to get the DBA's attention.  psql's backslash commands are far
> less likely to be used noninteractively, and a failure is usually pretty
> obvious to a human user.

yep if the scope of problem is limited to \d commands *only* its a nonissue
(i was not knowing it). in most automations i think psql  would only be acting
as a conduit for SQL commands. hence the concerns  were not well founded.

Warm Regds
Mallah.

>
> 2. pg_dump is critical: if it dumps an unusable backup due to not
> understanding the system catalogs of a newer server, the DBA who needs
> that backup later will be badly screwed.  psql's backslash commands,
> again, are not so critical.
>
> 3. psql offers a pretty decent amount of functionality even if some of
> its backslash commands don't work, whereas a dump that is wrong is worse
> than useless.  So the use-case for operating with a version mismatch is
> much wider for psql.
>
> So I think we have the right tradeoffs in this regard now.
>
>                         regards, tom lane
>



Message-ID: <a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com>
Permalink:  ../a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com/
Also on:    postgresql.org/message-id/a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: mallah.rajesh@gmail.com, tgl@sss.pgh.pa.us
  Subject: Re: Should clients abort in case of server version mismatch ? [ subject modf: as they already warn ]
  In-Reply-To: <a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com>
  References: <a97c77030612080746h7f70197bua57c191804b58c46@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox