Re: Database system identifier via SELECT?

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Chris Redekop <chris(at)replicon(dot)com>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Database system identifier via SELECT?
Date: 2011-12-08 20:57:24
Message-ID: 201112082057.pB8KvOU19242@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Chris Redekop wrote:
> Is there any way to get the database system identifier via a select
> statement? I have a primary/secondary async replication setup, and I'd
> like be able to verify from the client side that the provided primary and
> secondary connection strings do in fact refer to the same data set...

Wow, that is a reasonable thing to want available via SQL, but I can't
see a way to get to it.

The only method I can suggest is to write a server-side C function that
calls GetSystemIdentifier().

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ It's impossible for everything to be true. +

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joshua D. Drake 2011-12-08 21:11:19 Re: Database system identifier via SELECT?
Previous Message Simon Riggs 2011-12-08 20:16:11 Re: Clarification on CONTEXT: xlog redo xid assignment