Re: BUG #18240: Undefined behaviour in cash_mul_flt8() and friends

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: David Rowley <dgrowleyml(at)gmail(dot)com>
Cc: Michael Paquier <michael(at)paquier(dot)xyz>, exclusion(at)gmail(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #18240: Undefined behaviour in cash_mul_flt8() and friends
Date: 2023-12-12 14:37:58
Message-ID: 2433182.1702391878@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

David Rowley <dgrowleyml(at)gmail(dot)com> writes:
> On Tue, 12 Dec 2023 at 22:03, Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>> And numeric has much better code coverage and support. I am wondering
>> whether we've reached the point where it would be better to remove it
>> entirely from the tree, and just tell people to use numeric.

> We could extract it into a contrib module.

Perhaps, but ...

> That might help reduce new usages of it and would also allow people
> who have large tables using the money type but can't realistically
> wait out a table rewrite to upgrade to a newer version of Postgres.

... I doubt that a contrib module would solve the problem for people
who can't afford a rewrite. pg_upgrade requires that datatype OIDs
stay the same, which is something I don't believe a contrib module
could manage. We've run into that before if memory serves. Is it
time to do something about that? Perhaps we could allow extension
modules to use binary_upgrade_set_next_pg_type_oid, and then somehow
reserve the money and _money OIDs forever?

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2023-12-12 15:09:35 Re: BUG #18242: pg_dump with non-superuser from pg14 to pg15 fails on ALTER FUNCTION
Previous Message Dean Rasheed 2023-12-12 13:16:09 Re: BUG #18238: Cross-partitition MERGE/UPDATE with delete-preventing trigger leads to incorrect memory access