pgjdbc/pgjdbc GitHub issues and pull requests (mirror)  
help / color / mirror / Atom feed
From: cgm-aw (@cgm-aw) <[email protected]>
To: pgjdbc/pgjdbc <[email protected]>
Subject: Re: [pgjdbc/pgjdbc] PR #3606: fix: add support for multiple schemas via PgConnection.setSchema
Date: Wed, 23 Apr 2025 09:16:26 +0000
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

So how do we proceed?
My proposal: we keep the PR as it is, `getSchema()` will not be changed. 

My reasoning behind this is: Currently, if I set multiple schemas for a user via `ALTER ROLE <user> SET search_path = schema1,schema2` or via JDBC connection string and then call `getSchema()` via JDBC, I will only get one schema back.
So people already expect `getSchema()` to only return one schema, even if they configured multiple. 

A change in `getSchema()` is unexpected and Postgres states that `current_schema()` only returns one schema.
Someone who wants to see all schemas can still call `SHOW search_path`.

view thread (19+ messages)  latest in thread

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 using the --to and --cc options:
  reply via email

  To: github://pgjdbc/pgjdbc
  Cc: [email protected], [email protected]
  Subject: Re: [pgjdbc/pgjdbc] PR #3606: fix: add support for multiple schemas via PgConnection.setSchema
  In-Reply-To: <<[email protected]>>

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

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