Re: [PATCH v2] Avoid internal error for invalid interval typmods

From: Haibo Yan <tristan(dot)yim(at)gmail(dot)com>
To: Feng Wu <wufengwufengwufeng(at)gmail(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: [PATCH v2] Avoid internal error for invalid interval typmods
Date: 2026-07-01 03:26:51
Message-ID: CABXr29ERr=LsyLQnVwxZtSAqhRqJKvs2H2OO9uTrHWCO4P_5sA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Jun 30, 2026 at 6:49 PM Feng Wu <wufengwufengwufeng(at)gmail(dot)com> wrote:
>
> Hi Haibo,
>
> Thanks for reviewing.
>
> I agree that the SQL-callable pg_catalog.interval(interval, int4) path is the
> important case to cover here. The v1 test was already exercising that direct
> call, but it used a DO block intentionally so that the regression test checks
> the SQLSTATE is invalid_parameter_value, rather than only matching the error
> message text.
>
> In v2, I kept that structure and updated the test comment to make this clearer.
>
> Regards,
> Feng

Thank you for fixing this. v2 looks good to me.

Regards
Haibo

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bertrand Drouvot 2026-07-01 03:39:37 Re: Add pg_stat_kind_info system view
Previous Message Michael Paquier 2026-07-01 03:18:23 Re: Refactor function pg_get_multixact_stats (src/backend/utils/adt/multixactfuncs.c)