On Wed, 4 Jun 2025 at 07:22, Matthew Tice wrote:
> Tue 03 Jun 2025 07:13:11 PM UTC (every 1s)
> n_dead_tup | 5038
> autoanalyze_count | 3078
> Tue 03 Jun 2025 07:13:12 PM UTC (every 1s)
> n_dead_tup | 1290579
> autoanalyze_count | 3079
> I don't understand where this large
On 03/06/2025 20:01, Adrian Klaver wrote:
On 6/3/25 11:18, Ray O'Donnell wrote:
On 03/06/2025 17:53, Tom Lane wrote:
Thanks a million for the explanation, Tom - that makes sense. I tried
what you suggested, with mixed results:
(i) Running the MERGE as a stand-alone query, with just RETURNIN
"Ray O'Donnell" writes:
> (iii) Running (ii) but with the order of the items in RETURNING reversed -
> ... returning t, merge_action() into m_new, m_action
> - gave me a different error:
> ERROR: record variable cannot be part of multiple-item INTO list
> LINE 53: m, merge_action() i
Hi all,
While investigating some potential vacuum improvements to make to a table I
happened to notice that one table (along with others) will suddenly increase
the number of n_dead_tup reported in pg_stat_user_tables without a
corresponding increase in the inserts, updates, or deletes.
For in
On 6/3/25 11:18, Ray O'Donnell wrote:
On 03/06/2025 17:53, Tom Lane wrote:
Thanks a million for the explanation, Tom - that makes sense. I tried
what you suggested, with mixed results:
(i) Running the MERGE as a stand-alone query, with just RETURNING... ,
worked - I got a scalar and a row a
On 03/06/2025 17:53, Tom Lane wrote:
"Ray O'Donnell" writes:
Can you combine scalar and row types in a RETURNING clause?
I think so.
declare
m_action text;
m_new_data record;
begin
merge into my_table t
using (
) s
on (t.id = s.id)
whe
"Ray O'Donnell" writes:
> Can you combine scalar and row types in a RETURNING clause?
I think so.
> declare
> m_action text;
> m_new_data record;
> begin
> merge into my_table t
> using (
>
> ) s
> on (t.id = s.id)
> when matched then
> u
Can you combine scalar and row types in a RETURNING clause?
My use-case is getting the results of a MERGE - I'd like to be able to
capture both the action performed and the modified row, something like
this (this is in a plpgsql function):
declare
m_action text;
m_new_data record;
beg
On Wed, Jun 26, 2024 at 2:25 PM Dominique Devienne wrote:
> On Wed, Jun 26, 2024 at 11:08 AM Laurenz Albe
> wrote:
> > On Wed, 2024-06-26 at 10:35 +0200, Dominique Devienne wrote:
> > > So I have two questions:
> > > 1) Is there any way to know the current_role of the caller of a
> > > DEFINER f