From: | Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> |
---|---|
To: | Ken Kato <katouknl(at)oss(dot)nttdata(dot)com> |
Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: [PATCH] Add min() and max() aggregate functions for xid8 |
Date: | 2022-02-07 01:45:34 |
Message-ID: | 15ee201d-b8eb-5f35-2639-ad5b4b2ef335@oss.nttdata.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2022/02/05 10:46, Ken Kato wrote:
> Thank you for the comments.
> I sent my old version of patch by mistake.
> This is the updated one.
Thanks!
+ PG_RETURN_FULLTRANSACTIONID((FullTransactionIdFollowsOrEquals(fxid1, fxid2)) ? fxid1 : fxid2);
Basically it's better to use less 80 line length for readability. So how about change the format of this to the following?
if (FullTransactionIdFollows(fxid1, fxid2))
PG_RETURN_FULLTRANSACTIONID(fxid1);
else
PG_RETURN_FULLTRANSACTIONID(fxid2);
+insert into xid8_tab values ('0'::xid8), ('18446744073709551615'::xid8);
Isn't it better to use '0xffffffffffffffff'::xid8 instead of '18446744073709551615'::xid8, to more easily understand that this test uses maximum number allowed as xid8?
In addition to those two xid8 values, IMO it's better to insert also the xid8 value neither minimum nor maximum xid8 ones, for example, '42'::xid8.
Regards,
--
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2022-02-07 02:40:12 | Re: GUC flags |
Previous Message | Kyotaro Horiguchi | 2022-02-07 01:16:34 | Re: Add checkpoint and redo LSN to LogCheckpointEnd log message |