[jira] [Assigned] (SPARK-21365) Deduplicate logics parsing DDL-like type definition

2017-07-11 Thread Wenchen Fan (JIRA)

 [ 
https://issues.apache.org/jira/browse/SPARK-21365?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Wenchen Fan reassigned SPARK-21365:
---

Assignee: Hyukjin Kwon

> Deduplicate logics parsing DDL-like type definition
> ---
>
> Key: SPARK-21365
> URL: https://issues.apache.org/jira/browse/SPARK-21365
> Project: Spark
>  Issue Type: Improvement
>  Components: PySpark
>Affects Versions: 2.2.0
>Reporter: Hyukjin Kwon
>Assignee: Hyukjin Kwon
> Fix For: 2.3.0
>
>
> It looks we duplicate 
> https://github.com/apache/spark/blob/d492cc5a21cd67b3999b85d97f5c41c3734b1ba3/python/pyspark/sql/types.py#L823-L845
>  logic for parsing DDL-like type definitions.
> There are also two more points here:
> - This does not support "field type" but "field: type".
> - This does not support nested schemas. For example as below:
> {code}
> >>> spark.createDataFrame([[[1]]], "struct>").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a: struct").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a int").show()
> ...
> ValueError: Could not parse datatype: a int
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

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



[jira] [Assigned] (SPARK-21365) Deduplicate logics parsing DDL-like type definition

2017-07-10 Thread Apache Spark (JIRA)

 [ 
https://issues.apache.org/jira/browse/SPARK-21365?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-21365:


Assignee: (was: Apache Spark)

> Deduplicate logics parsing DDL-like type definition
> ---
>
> Key: SPARK-21365
> URL: https://issues.apache.org/jira/browse/SPARK-21365
> Project: Spark
>  Issue Type: Improvement
>  Components: PySpark
>Affects Versions: 2.2.0
>Reporter: Hyukjin Kwon
>
> It looks we duplicate 
> https://github.com/apache/spark/blob/d492cc5a21cd67b3999b85d97f5c41c3734b1ba3/python/pyspark/sql/types.py#L823-L845
>  logic for parsing DDL-like type definitions.
> There are also two more points here:
> - This does not support "field type" but "field: type".
> - This does not support nested schemas. For example as below:
> {code}
> >>> spark.createDataFrame([[[1]]], "struct>").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a: struct").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a int").show()
> ...
> ValueError: Could not parse datatype: a int
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

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



[jira] [Assigned] (SPARK-21365) Deduplicate logics parsing DDL-like type definition

2017-07-10 Thread Apache Spark (JIRA)

 [ 
https://issues.apache.org/jira/browse/SPARK-21365?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-21365:


Assignee: Apache Spark

> Deduplicate logics parsing DDL-like type definition
> ---
>
> Key: SPARK-21365
> URL: https://issues.apache.org/jira/browse/SPARK-21365
> Project: Spark
>  Issue Type: Improvement
>  Components: PySpark
>Affects Versions: 2.2.0
>Reporter: Hyukjin Kwon
>Assignee: Apache Spark
>
> It looks we duplicate 
> https://github.com/apache/spark/blob/d492cc5a21cd67b3999b85d97f5c41c3734b1ba3/python/pyspark/sql/types.py#L823-L845
>  logic for parsing DDL-like type definitions.
> There are also two more points here:
> - This does not support "field type" but "field: type".
> - This does not support nested schemas. For example as below:
> {code}
> >>> spark.createDataFrame([[[1]]], "struct>").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a: struct").show()
> ...
> ValueError: The strcut field string format is: 'field_name:field_type', but 
> got: a: struct
> {code}
> {code}
> >>> spark.createDataFrame([[[1]]], "a int").show()
> ...
> ValueError: Could not parse datatype: a int
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

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