Re: Patch: shouldn't timezone(text, timestamp[tz]) be STABLE?

From: Aleksander Alekseev <aleksander(at)timescale(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Patch: shouldn't timezone(text, timestamp[tz]) be STABLE?
Date: 2021-09-06 10:10:01
Message-ID: CAJ7c6TN-9OJWbkmsYLmm8vgX-zZZXdUGSEzrXWHv0Y-v5BE66g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> BTW, it's customary to *not* include catversion bumps in submitted
> patches

Thanks, Tom.

> Anyway, attached is a revised patch that gets rid of the antique
> code, and it produces correct results AFAICT.

I tested your patch against the current master branch 78aa616b on
MacOS Catalina. I have nothing to add to the patch.

> I'm fairly unhappy now that we don't have any
> regression test coverage for this function.

Yep, that's unfortunate. I see several tests for `AT TIME ZONE`
syntax, which is a syntax sugar to timezone() with timestamp[tz]
arguments. But considering how `timetz` type is broken in the first
place [1], I'm not surprised few people feel motivated to do anything
related to it. Do you think there is a possibility that one day we may
be brave enough to get rid of this type?

[1]: https://wiki.postgresql.org/wiki/Don%27t_Do_This#Don.27t_use_timetz

--
Best regards,
Aleksander Alekseev

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2021-09-06 10:34:40 Re: [BUG] Failed Assertion in ReorderBufferChangeMemoryUpdate()
Previous Message r.takahashi_2@fujitsu.com 2021-09-06 10:06:37 RE: Implementing Incremental View Maintenance