diff options
author | Davies Liu <davies@databricks.com> | 2016-08-15 12:41:27 -0700 |
---|---|---|
committer | Josh Rosen <joshrosen@databricks.com> | 2016-08-15 12:41:27 -0700 |
commit | fffb0c0d19a2444e7554dfe6b27de0c086112b17 (patch) | |
tree | dc2fc14a9820672633b61b6acdf4a3d76985caf1 /sql/core/src/test | |
parent | 5da6c4b24f512b63cd4e6ba7dd8968066a9396f5 (diff) | |
download | spark-fffb0c0d19a2444e7554dfe6b27de0c086112b17.tar.gz spark-fffb0c0d19a2444e7554dfe6b27de0c086112b17.tar.bz2 spark-fffb0c0d19a2444e7554dfe6b27de0c086112b17.zip |
[SPARK-16700][PYSPARK][SQL] create DataFrame from dict/Row with schema
## What changes were proposed in this pull request?
In 2.0, we verify the data type against schema for every row for safety, but with performance cost, this PR make it optional.
When we verify the data type for StructType, it does not support all the types we support in infer schema (for example, dict), this PR fix that to make them consistent.
For Row object which is created using named arguments, the order of fields are sorted by name, they may be not different than the order in provided schema, this PR fix that by ignore the order of fields in this case.
## How was this patch tested?
Created regression tests for them.
Author: Davies Liu <davies@databricks.com>
Closes #14469 from davies/py_dict.
Diffstat (limited to 'sql/core/src/test')
0 files changed, 0 insertions, 0 deletions