Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tPzQh-00Graq-8E for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Dec 2024 07:34:11 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tPzQf-002sbd-7u for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Dec 2024 07:34:08 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tPzQe-002sZv-2h for pgsql-hackers@lists.postgresql.org; Tue, 24 Dec 2024 07:34:08 +0000 Received: from fout-a3-smtp.messagingengine.com ([103.168.172.146]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tPzQZ-001Lx1-Ps for pgsql-hackers@lists.postgresql.org; Tue, 24 Dec 2024 07:34:06 +0000 Received: from phl-compute-02.internal (phl-compute-02.phl.internal [10.202.2.42]) by mailfout.phl.internal (Postfix) with ESMTP id 45EA213801B4; Tue, 24 Dec 2024 02:34:02 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-02.internal (MEProxy); Tue, 24 Dec 2024 02:34:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm2; t=1735025642; x=1735112042; bh=jUfkWKr8yA 2kW+29QO1GcuNJbx6qCtdkE5DZong4CwI=; b=OXMOATNiqOR60kQWcKJO9pmIO+ CLt5qdc/qxqpToJ7H4HDj+sqZbdiivAHQCiYHRiUwYMx8tyqQ/OcOpSv7K3zc2hP hJ/BoRkCaJ1cHX0hjYyBE8kwsYzXJ0cTMC8I2zogipXXcV//wGwdA9aiilakxx76 yckf8bkPbozR4OIECuKmN2zckLlM/9+Jt5F+Fmpy1TQTE0R4P6pMJNVp+NweVFEn Dy6bIqspP7ggiK4A8Hfb0x2qy+wlntvkxOYfH/GocW3Wd4lBJ9ozM1FljJNXYdPb JYctoGPHa0+ntNpTegRfAJuefwlBb/VioXh23+oDxmInO0P48Z7MbGdphkrg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t= 1735025642; x=1735112042; bh=jUfkWKr8yA2kW+29QO1GcuNJbx6qCtdkE5D Zong4CwI=; b=HQuv8fCwaARM55ZXJVboEV4Yqfj1318jW+1byo5tn7wc3bKsJ/w AD6UrfNFYqHJxkCg/HgPD9DM3MZ9768fXnM80qu2qJN/suS50tKDQlOXtk08YGi7 TXSYPtvBCOaRms+fqHBoQ80+njjAuqil3W/dgf03HZ5xTvXVlEJ/4DnbjOfMCOdt rmE1mg680hrgLgihk3TpHVFsV01JVMHAfX9mYKOyARUTIO2Psvdw4znrH1nz4sRW vXM9OZftvlWU5I19ROcIUeIURCeM0Nt3Mo/hebnRRkuiPOMKuHqvw+TfdI4Rs9I2 XhVUkAl/a/8GUSzxRh1U6wsnyCUCJP6AsCg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddruddufedguddtjecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenfghrlhcuvffnffculdejtddmnecujfgurhepfffhvfevuffk fhggtggujgesghdtreertddtvdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrh cuoehmihgthhgrvghlsehprghquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpeet leeifedufffhhfdtteelgeeggeffhfekueevteeigfduudevudetgfegiedvjeenucevlh hushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehmihgthhgrvghl sehprghquhhivghrrdighiiipdhnsggprhgtphhtthhopedvpdhmohguvgepshhmthhpoh huthdprhgtphhtthhopehkohhshhihgeegsehgmhgrihhlrdgtohhmpdhrtghpthhtohep phhgshhqlhdqhhgrtghkvghrsheslhhishhtshdrphhoshhtghhrvghsqhhlrdhorhhg X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 24 Dec 2024 02:34:00 -0500 (EST) Date: Tue, 24 Dec 2024 16:33:47 +0900 From: Michael Paquier To: Joseph Koshakow Cc: PostgreSQL Hackers Subject: Re: date_trunc invalid units with infinite value Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="rQAJubo2rkzNry5p" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --rQAJubo2rkzNry5p Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Dec 05, 2024 at 02:34:41PM +0900, Michael Paquier wrote: > I agree that it is inconsistent that we allow infinite values to go > through this function call even for fields that are not listed as > supported by the documentation. So, yes, I think that what you are > doing the right thing by applying the check based on the units > supported, but I also doubt that it is something that we could > backpatch as it would cause queries to work now to suddenly break. >=20 > Thoughts and comments from others are welcome. Hearing nothing, I have looked at this patch again and I think that I'm OK with your proposal. While the discrepancy is annoying for back-branches, this causes a slight change of behavior, so I have no backpatch in mind. I am planning to get this one applied around the end of this week on Friday for HEAD, that should be enough if there are comments and/or objections. -- Michael --rQAJubo2rkzNry5p Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmdqY9sACgkQnvQgOdby QH2hoQ//ftnbU2LuONAD/RpdW5m9lDwgbQU1CZEad3dX1WrtkBIU7TpjifHPLBwe u1HEKlOoFqqkgX+0J/1JwBSaKSrrihuFjxj4zS7XQdn3sH2YvuB1zBpEfRzfUvfX SVXZ7V9za/lU4plVJr+Pzxgjj+1jUf8YzQC+mKsiQdzbs0Vbq40sQfLqpDvtKMJy /HoNdQ9T1Ajof3Zla+lmcus4aM5w3i5LqqqZN6AYna9jZCdJum9f7h9TSPnUC2uA ENyu5jO8VVupbpL2g6z7ynfVXPnfSJHdlAj8hwHo1VyjX6nbDE6iDeCPkDm+Wbpc /75blpGUfF/1drJMoodTaYNOnIfw69kaosVWyo92aS+J7oFFUm6+g+rMVBvXy3LB KM8z3LR6Xx6Z+1sq5zPiVms3s0Hpdjb4s4DHYZzGOp95+jyl4EwC32dMzPrKOJyh n9EUYIa78lk3zn7z5C2P0Bp1s0LrtzVVBDIAEKZBsPuwvXySPqZXggtkXke3PT6V KrxMGswoULeg5p6F7MVaOVga19HSxQlmbiM3TEEFf/hNQWmLSqyg4kBpz2HJ455p fQFHepj0gAClfgAWBaEgkVCDmaslxN6bVosF3X539D1Guz099/WtO2HyAi21EPth Y7+k/KVAR7F02aamX/KqxmRBDpSEO+DWYqVusKjI0IX6kDphgKI= =SDGN -----END PGP SIGNATURE----- --rQAJubo2rkzNry5p--