Omega359 opened a new issue, #8987: URL: https://github.com/apache/arrow-datafusion/issues/8987
### Is your feature request related to a problem or challenge? In a similar vein to #8886 I believe it would be useful to have a to_date function that mirrors the functionality found in [postgresql](https://www.postgresql.org/docs/current/functions-formatting.html) and [spark](https://spark.apache.org/docs/latest/api/sql/#to_date). The format options however would follow the same pattern as #8886 and use the chrono library's formats (at least for the initial implementation) Passing a single argument to the function would behave in a similar manner to the to_timestamp function where it was attempt to infer the date from either a number type (inferred as seconds/millis/etc since epoch), a timestamp or a utf8/largeutf8 string. arrow-cast has a parse_date function invoked from the cast from string -> date32 that seems to handle a few common formats that can be documented in the user guide and examples. The return type of this new function would be Date32 for arrow, Date for SQL. ### Describe the solution you'd like A to_date(expr[,.format_n]) function that can be invoked from a dataframe or via sql in the same manner as to_timestamp. ### Describe alternatives you've considered The basic implementation can likely be done using arrow_cast functionality currently however having a full function would allow for additional formatting options. ### Additional context _No response_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
