Re: Question on trigger

2024-04-11 Thread Adrian Klaver
On 4/11/24 07:31, veem v wrote: Hi, We used to use Oracle database in which we had audit triggers(something as below) mandated for all tables by the control team. Now we are going to use the postgresql 15.4 database for one of our applications. So,wanted to understand if there exists any

Re: subquery plan rows = 1, but it's merge joined instead of index lookup

2024-04-11 Thread Ilya Basin
Yes! "set join_collapse_limit = 9" was enough to fix the plan, thanks Laurenz. I will set both to 11. Original Message From: Laurenz Albe [mailto:laurenz.a...@cybertec.at] Sent: Thursday, April 11, 2024 at 14:21 UTC To: ilya Basin; pgsql-general@lists.postgresql.org Subject:

Question on trigger

2024-04-11 Thread veem v
Hi, We used to use Oracle database in which we had audit triggers(something as below) mandated for all tables by the control team. Now we are going to use the postgresql 15.4 database for one of our applications. So,wanted to understand if there exists any downside of such audit trigger setup for

Re: subquery plan rows = 1, but it's merge joined instead of index lookup

2024-04-11 Thread Laurenz Albe
On Thu, 2024-04-11 at 15:57 +0300, ilya Basin wrote: > Is there some complexity limit after which the planner starts acting dumb? Yes, "join_collapse_limit" and "from_collapse_limit". You can try increasing them. Yours, Laurenz Albe

Re: (When) can a single SQL statement return multiple result sets?

2024-04-11 Thread Tom Lane
Thomas Kellerer writes: > Tom Lane schrieb am 11.04.2024 um 01:02: >> Jan Behrens writes: >>> While writing a PostgreSQL client library for Lua supporting >>> Pipelining (using PQsendQueryParams), I have been wondering if there >>> are any single SQL commands that return multiple result sets.

Re: Postgres_FDW doc doesn't specify TYPE support in Remote Execution Options

2024-04-11 Thread Rajan Pandey
Hi, please ignore my last email about the patch. :/ I have determined that pushdown of custom data types through fdw in fact does make sense. Consider this query: SELECT * FROM customers WHERE ; To push down the WHERE clause to the foreign servers, both local and foreign server must have the

RE: (When) can a single SQL statement return multiple result sets?

2024-04-11 Thread Patrick FICHE
-Original Message- From: Jan Behrens Sent: Wednesday, April 10, 2024 11:23 PM To: pgsql-general@lists.postgresql.org Subject: (When) can a single SQL statement return multiple result sets? Hello, While writing a PostgreSQL client library for Lua supporting Pipelining (using

Re: Two server instances on one server

2024-04-11 Thread Andreas Wagner
Am Mittwoch, dem 10.04.2024 um 16:41 -0400 schrieb Tom Lane: > Andreas Wagner writes: > > I consider using two instances of the PG server on one node. The > > node > > has two processors and each processor has 64GB memory assigned to > > it. > > I'd like to > > * restrict instance one to