Re: [PATCH] Add min() and max() aggregate functions for xid8
От | Fujii Masao |
---|---|
Тема | Re: [PATCH] Add min() and max() aggregate functions for xid8 |
Дата | |
Msg-id | 69d9da54-7066-dcc2-5efd-5fdad139bc40@oss.nttdata.com обсуждение исходный текст |
Ответ на | [PATCH] Add min() and max() aggregate functions for xid8 (Ken Kato <katouknl@oss.nttdata.com>) |
Ответы |
Re: [PATCH] Add min() and max() aggregate functions for xid8
|
Список | pgsql-hackers |
On 2022/02/03 16:45, Ken Kato wrote: > Hi hackers, > > Unlike xid, xid8 increases monotonically and cannot be reused. > This trait makes it possible to support min() and max() aggregate functions for xid8. > I thought they would be useful for monitoring. > > So I made a patch for this. Thanks for the patch! +1 with this feature. + PG_RETURN_FULLTRANSACTIONID((U64FromFullTransactionId(fxid1) > U64FromFullTransactionId(fxid2)) ? fxid1 : fxid2); Shouldn't we use FullTransactionIdFollows() to compare those two fxid values here, instead? + PG_RETURN_FULLTRANSACTIONID((U64FromFullTransactionId(fxid1) < U64FromFullTransactionId(fxid2)) ? fxid1 : fxid2); Shouldn't we use FullTransactionIdPrecedes() to compare those two fxid values here, instead? Could you add the regression tests for those min() and max() functions for xid8? Regards, -- Fujii Masao Advanced Computing Technology Center Research and Development Headquarters NTT DATA CORPORATION
В списке pgsql-hackers по дате отправления: