On Sun, Jan 23, 2022 at 01:31:03PM -0500, Tom Lane wrote:
> We could consider a more global change to get rid of using
> appendPQExpBuffer where it's not absolutely necessary, so that
> there are fewer bad examples to copy. Another idea is to deem
> it an anti-pattern to end a query with a semicolon. But I don't
> have a lot of faith in people following those coding rules in
> future, either. It'd also be a lot of code churn for what is
> in the end a relatively harmless bug.
Could a backend-side, run-time configurable developper GUC,
potentially help here? This could look after multiple queries in code
paths where we don't want any, once you combine it with a specific
compilation flag à-la-ENFORCE_REGRESSION_TEST.
--
Michael