pgjdbc/pgjdbc GitHub issues and pull requests (mirror)
help / color / mirror / Atom feedFrom: vlsi (@vlsi) <[email protected]>
To: pgjdbc/pgjdbc <[email protected]>
Subject: Re: [pgjdbc/pgjdbc] PR #3528: Implement performance fix for catalog check in DatabaseMetaData
Date: Wed, 09 Apr 2025 18:39:13 +0000
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
I think it should be uncommon for the client code to ask for a list of "procedures in a foreign catalog", so it should be fine to go with `and false` trick.
At the same time, certain cases make it easy to return empty resultset without making a database roundtrip.
@SophiahHo , in some of the cases, we use `org.postgresql.core.BaseStatement#createDriverResultSet(Field[] fields, List<Tuple> tuples)` can create resultset. For instance, `getProcedureColumns` prepares `Field[]` declaration, and then it executes a query.
In that case we could use something like
```java
if (catalog != null && !catalog.equals(...)) {
// Returns empty resultset
((BaseStatement) createMetaDataStatement()).createDriverResultSet(f, v)
}
```
I guess Dave meant something like that. WDYT?
view thread (11+ 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 #3528: Implement performance fix for catalog check in DatabaseMetaData
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