Re: Determine if postgresql cluster running is primary or not - Mailing list pgsql-general

From Raul Kaubi
Subject Re: Determine if postgresql cluster running is primary or not
Date
Msg-id CAO_+3-C=SNTMgDNhyNof54EBENHc+moej9Ky4Wdf1sYrmWKoeQ@mail.gmail.com
Whole thread Raw
In response to Re: Determine if postgresql cluster running is primary or not  (Paul Förster <paul.foerster@gmail.com>)
Responses Re: Determine if postgresql cluster running is primary or not
List pgsql-general
Hmm, ok.

But how is this possible..?

 when b.sender>0 and c.receiver>0 then
            'Primary+Replica'

Raul

Kontakt Paul Förster (<paul.foerster@gmail.com>) kirjutas kuupäeval R, 20. november 2020 kell 12:04:
Hi Raul,

> On 20. Nov, 2020, at 10:41, Raul Kaubi <raulkaubi@gmail.com> wrote:
>
> Hi
>
> Thanks.
> Seems like 9.5 does not work.
>
> ERROR:  relation "pg_stat_wal_receiver" does not exist
> LINE 20:         from pg_stat_wal_receiver
>
> Any ide how to achieve this in 9.5 ?
>
> Raul

this query is tested to work on 10.x and newer, not 9.x. I don't have 9.x, so I can't say, sorry.

Cheers,
Paul

pgsql-general by date:

Previous
From: Roger Wolff
Date:
Subject: Re: Recovering old installation.
Next
From: Paul Förster
Date:
Subject: Re: Determine if postgresql cluster running is primary or not