public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tom Lane <[email protected]>
To: Richard Guo <[email protected]>
Cc: Swirl Smog Dowry <[email protected]>
Cc: [email protected]
Subject: Re: pg_get_viewdef() produces non-round-trippable SQL for views with USING join on mismatched integer types
Date: Fri, 27 Feb 2026 10:21:43 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAMbWs49AUBVtMG=BXwfB5xdg1Zd9dwJg42C1hLayYtO2Kmxqpw@mail.gmail.com>
References: <CA+-gibjCg_vjcq3hWTM0sLs3_TUZ6Q9rkv8+pe2yJrdh4o4uoQ@mail.gmail.com>
<[email protected]>
<[email protected]>
<CAMbWs4_FLicDsNpotM0uEFkeveJ+gULe4VP0PyJ=FVsD9iYCGA@mail.gmail.com>
<CAMbWs49AUBVtMG=BXwfB5xdg1Zd9dwJg42C1hLayYtO2Kmxqpw@mail.gmail.com>
Richard Guo <[email protected]> writes:
> I am on the fence about whether this fix is safe to back-patch to v18.
I don't think we have a lot of choice. The cases where it makes a
difference are pretty broken. Fortunately, I think these cases
are rare. JOIN USING combining two different-type columns has got
to be an edge-case usage, and I think it likely doesn't matter much
in other cases.
> However, this fix will only apply to newly created views. Users who
> have existing views affected by this bug will have to recreate them
> after upgrading to get the corrected pg_get_viewdef output.
Yeah :-(. What's really annoying is that probably people will not
notice until they try to upgrade to v19, and by then recreating
the view correctly might be difficult. But I'm not seeing a way
to smooth their path.
regards, tom lane
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected]
Subject: Re: pg_get_viewdef() produces non-round-trippable SQL for views with USING join on mismatched integer types
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox