Re: PG FDW query fails, works local, same credentials

2023-08-30 Thread Tom Lane
"Pete O'Such" writes: > I've got a view on server A (PG 15.2) that fails when queried via FDW from > server B (also PG 15.2). Querying it as a foreign table from server B > yields a message like "ERROR: function blah(type) does not exist". Check your search path assumptions. postgres_fdw runs

PG FDW query fails, works local, same credentials

2023-08-30 Thread Pete O'Such
I've got a view on server A (PG 15.2) that fails when queried via FDW from server B (also PG 15.2). Querying it as a foreign table from server B yields a message like "ERROR: function blah(type) does not exist". Confusingly, I succeed when: I log into server A, set my role to match the role used

Re: Partitionwise JOIN scanning all partitions, even unneeded ones

2023-08-30 Thread Dimitrios Apostolou
Thank you for the clear explanation, and I hope the missing optimisation gets implemented sooner rather than later. Maybe the query planner should consider the missing optimisation and ban *hash* partitionwise joins. Indeed I verified that disabling hash join fixed the situation, with both querie

Re: Partitionwise JOIN scanning all partitions, even unneeded ones

2023-08-30 Thread David Rowley
On Thu, 31 Aug 2023 at 07:55, Dimitrios Apostolou wrote: > I'd appreciate help on whether it's a real issue, and if it's unknown I > can forward this to the psql-bugs mailing list. I'd also appreciate any > critique on the clarity of my description and on my schema and queries, > since I'm new to

Re: event trigger clarification

2023-08-30 Thread David G. Johnston
On Wednesday, August 30, 2023, Marc Millas wrote: > Hi, > the doc v15 states: " pg_event_trigger_ddl_commands returns a list of DDL > commands > executed by each user action, when invoked in a function attached to a > ddl_command_end event trigger." > When some ddl command is executed within a b

Re: event trigger clarification

2023-08-30 Thread Erik Wienhold
> On 30/08/2023 17:12 CEST Marc Millas wrote: > > the doc v15 states: " pg_event_trigger_ddl_commands returns a list of DDL > commands executed by each user action, when invoked in a function attached > to a ddl_command_end event trigger." > When some ddl command is executed within a block, I woul

event trigger clarification

2023-08-30 Thread Marc Millas
Hi, the doc v15 states: " pg_event_trigger_ddl_commands returns a list of DDL commands executed by each user action, when invoked in a function attached to a ddl_command_end event trigger." When some ddl command is executed within a block, I would like to know if the event trigger fires when the li

Re: Calculating vm.nr_hugepages

2023-08-30 Thread Erik Wienhold
> On 30/08/2023 15:12 CEST Troels Arvin wrote: > > I assume I need to find the same value as I get from running "postgres > -C shared_memory_size_in_huge_pages". I call that my target value. > Note: I cannot simply run "postgres -C ...", because I need my Ansible > play to work against a server wh

Re: Calculating vm.nr_hugepages

2023-08-30 Thread Don Seiler
On Wed, Aug 30, 2023 at 8:12 AM Troels Arvin wrote: > Hello, > > I'm writing an Ansible play which is to set the correct value for > vm.nr_hugepages on Linux servers where I hope to make Postgres make use > of huge pages. > > However, I'm struggling to find the right formula. > > I assume I need

Calculating vm.nr_hugepages

2023-08-30 Thread Troels Arvin
Hello, I'm writing an Ansible play which is to set the correct value for vm.nr_hugepages on Linux servers where I hope to make Postgres make use of huge pages. However, I'm struggling to find the right formula. I assume I need to find the same value as I get from running "postgres -C shared

Re: Restoring default privileges on objects

2023-08-30 Thread Peter J. Holzer
On 2023-08-29 14:44:48 -0600, Stuart McGraw wrote: > On 8/29/23 13:27, Tom Lane wrote: > > Fixing \dp to honor "\pset null" for this might be a reasonable > > thing to do too. I'm actually a bit surprised that that doesn't > > work already. > > That change would still require someone using \dp to