Re: Hash Right join and seq scan

2024-07-07 Thread Justin Pryzby
Is the query fast with some bind parameters but slow with others? If so, it'd be better to show an explain with 'fast' and 'slow' bind params, rather than the same bind params with enable_*=off. Or is the change because autoanalyze runs on some table and changes the statistics enough to change th

Re: Hash Right join and seq scan

2024-07-07 Thread James Pang
Sorry for confusion, it's from attached explain output of the SQL. please check attached. my questions is : for nestloop of two partition tables , they use same partition key and equal join on partition key, the cost could be "outer tables estimated rows" * (average index scan of only one

Re: Low performance between datacenters

2024-07-07 Thread Vitalii Tymchyshyn
Often it happens because of the low batch size for fetching data. This makes client wait unnecessarily while reading rows. I am not sure which client are you using, but in java this can be controlled on per-statement level, see https://jdbc.postgresql.org/documentation/query/ I believe there is al

Re: Low performance between datacenters

2024-07-07 Thread Fernando Hevia
El dom, 7 jul 2024 a la(s) 3:17 p.m., Tamás PAPP (tomposm...@gmail.com) escribió: > hi All, > > I am new on the list. > I hope someone can give me an adequate answer or good advice about my > problem. > > I have a client (normally a web service, for testing the psql client) in > GCP. There is a PS

Low performance between datacenters

2024-07-07 Thread Tamás PAPP
hi All, I am new on the list. I hope someone can give me an adequate answer or good advice about my problem. I have a client (normally a web service, for testing the psql client) in GCP. There is a PSQL server in another DC. The ping response time is 20ms. I measured the bandwidth via scp and it