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/18 10:12:46 UTC

[jira] [Assigned] (SPARK-12421) Fix copy() method of GenericRow

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

Apache Spark reassigned SPARK-12421:
------------------------------------

    Assignee: Apache Spark

> Fix copy() method of GenericRow 
> --------------------------------
>
>                 Key: SPARK-12421
>                 URL: https://issues.apache.org/jira/browse/SPARK-12421
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 1.6.0
>            Reporter: Burkard Doepfner
>            Assignee: Apache Spark
>            Priority: Minor
>
> The copy() method of the GenericRow class does actually not copy itself. The method just returns itself.
> Simple reproduction code of the issue:
>  import org.apache.spark.sql.Row;
>     val row = Row.fromSeq(Array(1,2,3,4,5))
>     val arr = row.toSeq.toArray
>     arr(0) = 6
>     row // first value changed to 6
>     val rowCopied = row.copy()
>     val arrCopied = rowCopied.toSeq.toArray
>     arrCopied(0) = 7
>     row // first value still changed (to 7)



--
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