Re: jsonpath Time and Timestamp Special Cases - Mailing list pgsql-hackers

From David E. Wheeler
Subject Re: jsonpath Time and Timestamp Special Cases
Date
Msg-id F1D53A87-6785-4C7E-9F59-43B9B639D636@justatheory.com
Whole thread Raw
In response to jsonpath Time and Timestamp Special Cases  ("David E. Wheeler" <david@justatheory.com>)
Responses Re: jsonpath Time and Timestamp Special Cases
List pgsql-hackers
On Apr 29, 2024, at 20:45, David E. Wheeler <david@justatheory.com> wrote:

> I noticed that the jsonpath date/time functions (.time() and timestamp(), et al.) don’t support some valid but
special-casePostgreSQL values, notably `infinity`, `-infinity`, and, for times, '24:00:00`: 

Looking at ECMA-404[1], “The JSON data interchange syntax”, it says, of numbers:

> Numeric values that cannot be represented as sequences of digits (such as Infinity and NaN) are not
permitted.

So it makes sense that the JSON path standard would be the same, since such JSON explicitly cannot represent these
valuesas numbers. 

Still not sure about `24:00:00` as a time, though. I presume the jsonpath standard disallows it.

Best,

David

[1]: https://ecma-international.org/wp-content/uploads/ECMA-404_2nd_edition_december_2017.pdf




pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: Remove distprep
Next
From: Noah Misch
Date:
Subject: Re: datfrozenxid > relfrozenxid w/ crash before XLOG_HEAP_INPLACE