waitingkuo commented on issue #3096:
URL:
https://github.com/apache/arrow-datafusion/issues/3096#issuecomment-1210402986
extract has the same behavior
```bash
❯ select extract(hour from now());
Plan("Coercion from [Utf8, Timestamp(Nanosecond, Some(\"UTC\"))] to the
signature OneOf([Exact([Utf8, Date32]), Exact([Utf8, Date64]), Exact([Utf8,
Timestamp(Second, None)]), Exact([Utf8, Timestamp(Microsecond, None)]),
Exact([Utf8, Timestamp(Millisecond, None)]), Exact([Utf8, Timestamp(Nanosecond,
None)])]) failed.")
❯ select extract(hour from now()::timestamp);
+-------------------------------------------------------------------+
| datepart(Utf8("HOUR"),CAST(now() AS Timestamp(Nanosecond, None))) |
+-------------------------------------------------------------------+
| 6 |
+-------------------------------------------------------------------+
1 row in set. Query took 0.000 seconds.
```
--
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]