[SPARK-3407][SQL]Add Date type support

Hive returns null if `cast(cast('2014-09-18' as date) as int)`.