From: | Ron <ronljohnsonjr(at)gmail(dot)com> |
---|---|
To: | pgsql-general list <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Singleton SELECT inside cursor loop |
Date: | 2022-10-01 06:29:46 |
Message-ID: | ee9f6dc7-281d-f2a1-2556-54d36fd96e91@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
AWS RDS Postgresql 12.11
It runs quickly, no matter what the fetched cursor values are, as long as
the cursor returns less than 8 rows. After that, the singleton SELECT's
performance tanks.
We've got plenty of other procedures which have a similar "Singleton SELECT
inside a cursor" design (many even query the same table that the problematic
query does), but only this procedure's singleton SELECT tanks if the cursor
returns more than 8 rows.
It only runs once a month, so we've only just noticed the problem.
Why would that be? (We recently updated from 12.10 to 12.11, if that's
relevant.)
--
Angular momentum makes the world go 'round.
From | Date | Subject | |
---|---|---|---|
Next Message | Ron | 2022-10-01 07:22:22 | Example code Re: Singleton SELECT inside cursor loop |
Previous Message | Bryn Llewellyn | 2022-10-01 00:59:01 | Re: Limiting the operations that client-side code can perform upon its database backend's artifacts |