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

We probably need to compare the date conversion with Hive, https://github.com/apache/hive/blob/branch-0.12/serde/src/java/org/apache/hadoop/hive/serde2/objectinspector/primitive/PrimitiveObjectInspectorUtils.java#L1032

Particularly for `null` returns or throws exception.