Re: Re[2]: [PATCH] Add last_executed timestamp to pg_stat_statements

2025-12-11 Thread Sami Imseih
> >Can pg_stat_statements.stats_since help here? > > > >for example "where stats_since > last_poll_timestamp" ? > > Actually no, monitoring tools fetch snapshots to find the difference > between snapshots. > Data for every statement is changes after each execution. > > But stats_since is inserted o

Re[2]: [PATCH] Add last_executed timestamp to pg_stat_statements

2025-12-11 Thread Pavlo Golub
Hi Hi, Thanks for raising this. I did not look at the patch, but I have some high level comments. I would like to propose adding a last_executed timestamptz column to pg_stat_statements. This column records when each tracked statement was most recently executed. I do think there is valu

Re: [PATCH] Add last_executed timestamp to pg_stat_statements

2025-12-10 Thread Sami Imseih
Hi, Thanks for raising this. I did not look at the patch, but I have some high level comments. > I would like to propose adding a last_executed timestamptz column to > pg_stat_statements. This column records when each tracked statement > was most recently executed. I do think there is value in a

[PATCH] Add last_executed timestamp to pg_stat_statements

2025-12-10 Thread Pavlo Golub
Hello, I would like to propose adding a last_executed timestamptz column to pg_stat_statements. This column records when each tracked statement was most recently executed. The motivation comes from real world experience with monitoring tools like pgwatch that poll pg_stat_statements regularly. Cu