[SPARK-3007][SQL]Add "Dynamic Partition" support to Spark Sql hive

a new PR base on new master.  changes are the same as https://github.com/apache/spark/pull/1919
Added a test to validate dynamic partitioning folder layout by loading each partition from specific partition folder and check the contents.