Caused by: java.sql.SQLException: Year out of range.

Export to Excel.

I'm using getdatasubsetdownloadlinkfromrule to get the link to download the excel. The Link work fine if I don't filter the report with Date and Time criteria, if I use ToDate or FromDate in the report Search i get "Error 500 - Internal Server Error".
I have a DateTime field in the Table and my Report has Date field which I'm converting to datetime.

Error detail attached
Caused by: org.hibernate.exception.GenericJDBCException: could not execute query
...
...
Caused by: java.sql.SQLException: Year out of range.

OriginalPostID-163797

OriginalPostID-163797

  Discussion posts and replies are publicly visible