You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Hyukjin Kwon (Jira)" <ji...@apache.org> on 2021/07/19 10:59:00 UTC

[jira] [Resolved] (SPARK-35806) Mapping the `mode` argument to pandas in DataFrame.to_csv

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

Hyukjin Kwon resolved SPARK-35806.
----------------------------------
    Fix Version/s: 3.2.0
       Resolution: Fixed

Issue resolved by pull request 33414
[https://github.com/apache/spark/pull/33414]

> Mapping the `mode` argument to pandas in DataFrame.to_csv
> ---------------------------------------------------------
>
>                 Key: SPARK-35806
>                 URL: https://issues.apache.org/jira/browse/SPARK-35806
>             Project: Spark
>          Issue Type: Sub-task
>          Components: PySpark
>    Affects Versions: 3.2.0
>            Reporter: Haejoon Lee
>            Assignee: Haejoon Lee
>            Priority: Major
>             Fix For: 3.2.0
>
>
> pandas and pandas-on-Spark both have an argument named `mode` in the [DataFrame.to_csv, |https://koalas.readthedocs.io/en/latest/reference/api/databricks.koalas.DataFrame.to_csv.html]but the acceptable strings are different.
> pandas can accept the "w", "w+", "a", "a+" where as pandas-on-Spark can accept "append", "overwrite", "ignore", "error" or "errorifexists".
> We should map these acceptable strings to pandas.
> e.g. "w" will work as Spark's "overwrite". In addition, mode can take Spark's "overwrite" too.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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