dask-sql icon indicating copy to clipboard operation
dask-sql copied to clipboard

Add parser support for `timestampadd`

Open andygrove opened this issue 3 years ago • 0 comments

DataFusion's parser cannot parse timestampadd(year, 2, d) because year is not a keyword, so it assumes that this is an identifier and looks for a column with this name.

This PR works around the issue by providing a custom prefix parser in the DaskSqlDialect where we can override parsing of just this expression and then fall back to DataFusion. This is a new feature that was added to sqlparser relatively recently.

andygrove avatar Oct 12 '22 15:10 andygrove