Re: generate_series for timestamptz and time zone problem - Mailing list pgsql-hackers

From Tom Lane
Subject Re: generate_series for timestamptz and time zone problem
Date
Msg-id 38924.1655214183@sss.pgh.pa.us
Whole thread Raw
In response to Re: generate_series for timestamptz and time zone problem  (Przemysław Sztoch <przemyslaw@sztoch.pl>)
Responses Re: generate_series for timestamptz and time zone problem
List pgsql-hackers
=?UTF-8?Q?Przemys=c5=82aw_Sztoch?= <przemyslaw@sztoch.pl> writes:
> Please let me know what is the convention (procedure) of adding new
> functions to pg_proc. Specifically how oid is allocated.

See
https://www.postgresql.org/docs/devel/system-catalog-initial-data.html#SYSTEM-CATALOG-OID-ASSIGNMENT
(you should probably read that whole chapter for context).

> Therefore, should I add a second function timestamptz_pl_interval with
> three arguments, or should a function with a different name be added so
> that it does not get confused with operator functions (which only have
> two arguments)?

That's where you get into beauty-is-in-the-eye-of-the-beholder
territory.  There's some value in naming related functions alike,
but on the other hand I doubt timestamptz_pl_interval would have
been named so verbosely if anyone expected it to be called by
name rather than via an operator.  Coming up with good names is
part of the work of preparing a patch like this.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Przemysław Sztoch
Date:
Subject: Re: generate_series for timestamptz and time zone problem
Next
From: Justin Pryzby
Date:
Subject: Re: PG15 beta1 fix pg_stats_ext/pg_stats_ext_exprs view manual