You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Apache Spark (JIRA)" <ji...@apache.org> on 2015/12/10 04:20:10 UTC

[jira] [Commented] (SPARK-10947) With schema inference from JSON into a Dataframe, add option to infer all primitive object types as strings

    [ https://issues.apache.org/jira/browse/SPARK-10947?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15049952#comment-15049952 ] 

Apache Spark commented on SPARK-10947:
--------------------------------------

User 'stephend-realitymine' has created a pull request for this issue:
https://github.com/apache/spark/pull/9245

> With schema inference from JSON into a Dataframe, add option to infer all primitive object types as strings
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: SPARK-10947
>                 URL: https://issues.apache.org/jira/browse/SPARK-10947
>             Project: Spark
>          Issue Type: Improvement
>          Components: SQL
>    Affects Versions: 1.5.1
>            Reporter: Ewan Leith
>            Assignee: Stephen De Gennaro
>            Priority: Minor
>              Labels: releasenotes
>             Fix For: 1.6.0
>
>
> Currently, when a schema is inferred from a JSON file using sqlContext.read.json, the primitive object types are inferred as string, long, boolean, etc.
> However, if the inferred type is too specific (JSON obviously does not enforce types itself), this causes issues with merging dataframe schemas.
> Instead, we would like an option in the JSON inferField function to treat all primitive objects as strings.
> We'll create and submit a pull request for this for review.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org