I like the idea of transforming the Rex/Rel tree for the target dialect.
Via a RelOptRule or other means.
Or perhaps transform the SqlNode tree (which is how we deal with ORDER BY ...
NULLS LAST).
That’s better, in general, than making the SqlNode-to-string logic more and
more complex,
I guess in your approach, you need to maintain a customized
`SqlImplementor` ?
How about add a RelOptRule and detect pattern of "date + interval '1' DAY"
and use a RexShuttle to convert to "target_func(date, interval '1' DAY)"
Thus only a RelOptRule needs to be maintained.
Sachin Rohaj