Re: Allow to_date() and to_timestamp() to accept localized names
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>, Juan José Santamaría Flecha <juanjo.santamaria@gmail.com>, Arthur Zakirov <zaartur@gmail.com>, Tomas Vondra <tomas.vondra@2ndquadrant.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2020-01-24T16:22:59Z
Lists: pgsql-hackers
Alvaro Herrera <alvherre@2ndquadrant.com> writes: > But that's a different POV. The input to this function could come from > arbitrary user input from any application whatsoever. So the only > reason we can get away with that is because the example regression case > Juan José added (which uses non-normals) does not conform to the > standard. I'm unsure about "conforming to standard", but I think it's reasonable to put the onus of doing normalization when necessary on the user. Otherwise, we need to move normalization logic into basically all the string processing functions (even texteq), which seems like a pretty huge cost that will benefit only a small minority of people. (If it's not a small minority, then where's the bug reports complaining that we don't do it today?) regards, tom lane
Commits
-
Allow to_date/to_timestamp to recognize non-English month/day names.
- d67755049388 13.0 landed
-
Clean up formatting.c's logic for matching constant strings.
- fb12aefaafce 11.7 landed
- be13f227febc 12.2 landed
- a576f2a8f2e8 9.5.21 landed
- 9e24575f6f1b 9.6.17 landed
- 600b953d73ca 9.4.26 landed
- 212b870d6743 10.12 landed
- 4c70098ffa8c 13.0 landed
-
Implement standard datetime parsing mode
- 1a950f37d0a2 13.0 cited
-
Repair assorted issues in locale data extraction.
- 7ad1cd31bfcb 12.0 cited