Re: Document DateStyle effect on jsonpath string() - Mailing list pgsql-hackers

From David E. Wheeler
Subject Re: Document DateStyle effect on jsonpath string()
Date
Msg-id 7021EAF7-80C1-4116-B7A1-F8C2E0E29730@justatheory.com
Whole thread Raw
In response to Re: Document DateStyle effect on jsonpath string()  (Peter Eisentraut <peter@eisentraut.org>)
List pgsql-hackers
On Sep 10, 2024, at 16:10, Peter Eisentraut <peter@eisentraut.org> wrote:

> These JSON path functions are specified by the SQL standard, so they shouldn't depend on PostgreSQL-specific
settings. At least in new functionality we should avoid that, no? 

Does that also apply to `datetime(template)`, where it uses the `to_timestamp()` templates? From the docs[1]:

> The datetime() and datetime(template) methods use the same parsing rules as the to_timestamp SQL function does (see
Section9.8[2]), with three exceptions. First, these methods don't allow unmatched template patterns. Second, only the
followingseparators are allowed in the template string: minus sign, period, solidus (slash), comma, apostrophe,
semicolon,colon and space. Third, separators in the template string must exactly match the input string. 

Does the standard specify a formatting language?

Best,

David

[1]: https://www.postgresql.org/docs/devel/functions-json.html
[2]: https://www.postgresql.org/docs/devel/functions-formatting.html


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Speeding up ruleutils' name de-duplication code, redux
Next
From: "David E. Wheeler"
Date:
Subject: Re: Document DateStyle effect on jsonpath string()