alamb opened a new issue, #5652:
URL: https://github.com/apache/arrow-datafusion/issues/5652
**Is your feature request related to a problem or challenge? Please describe
what you are trying to do.**
I would like to write a query like
```sql
❯ select * from foo where x < now() - '1 day';
```
Here is what happens today
```sql
❯ create table foo(x timestamp) as select '2023-03-01'::timestamp;
0 rows in set. Query took 0.002 seconds.
❯ select * from foo;
+---------------------+
| x |
+---------------------+
| 2023-03-01T00:00:00 |
+---------------------+
1 row in set. Query took 0.001 seconds.
❯ select * from foo where x < now() - '1 day';
Internal error: The type of Timestamp(Nanosecond, Some("+00:00")) Minus Utf8
of binary physical should be same. This was likely caused by a bug in
DataFusion's code and we would welcome that you file an bug report in our issue
tracker
```
**Describe the solution you'd like**
I would like the query to work (by adding coercion rules to automatically
coerce string --> interval if appropriate)
**Describe alternatives you've considered**
N/A
**Additional context**
I think we will need to fix
https://github.com/apache/arrow-datafusion/issues/5650 and
https://github.com/apache/arrow-datafusion/issues/5651
--
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]