You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Marco Gaido (JIRA)" <ji...@apache.org> on 2018/01/25 08:24:00 UTC

[jira] [Resolved] (SPARK-23212) Casts the column to a different data type.

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

Marco Gaido resolved SPARK-23212.
---------------------------------
    Resolution: Invalid

This is not the right place. For questions, please use the user mailing list, as [https://spark.apache.org/community.html] describes.

> Casts the column to a different data type. 
> -------------------------------------------
>
>                 Key: SPARK-23212
>                 URL: https://issues.apache.org/jira/browse/SPARK-23212
>             Project: Spark
>          Issue Type: Question
>          Components: SparkR
>    Affects Versions: 2.1.0
>         Environment: I want to casts the column to a different data type.
>  
> {code:R}
> train_data   <- loadDF("./resultFile/train_data",
>                           "csv",
>                           header = TRUE)
> train_data$x1     <- cast(train_data$x1,     "double")
> train_data$x2     <- cast(train_data$x2,     "double")
> train_data$x3     <- cast(train_data$x3,     "double")
> train_data$x4     <- cast(train_data$x4,     "double")
> {code}
>  
> But my dataset has so many columns need to be cast,is there exist a convenient way to do it?
>            Reporter: 黄龙龙
>            Priority: Major
>              Labels: usability
>
> I want to casts the column to a different data type.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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