datafusion icon indicating copy to clipboard operation
datafusion copied to clipboard

Cast from string to date with "/"

Open matthewmturner opened this issue 1 year ago • 2 comments

Is your feature request related to a problem or challenge?

I want to be able to cast a string that is delimited with "/" to a date the same way that you can when it is delimited with "-". Postgres supports both.

image

Describe the solution you'd like

No response

Describe alternatives you've considered

No response

Additional context

No response

matthewmturner avatar May 16 '24 21:05 matthewmturner

I see there is https://github.com/apache/datafusion/issues/9331 with a draft PR on the arrow-rs side. I have checked in on that

matthewmturner avatar May 16 '24 21:05 matthewmturner

The to_date function might be an alternative. to_date('2024/01/01', '%Y/%m/%d');

Omega359 avatar May 17 '24 12:05 Omega359