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

Uroš Bojanić updated SPARK-59477:
---------------------------------
    Component/s: SQL
                     (was: Spark Core)

> Add CSV write option treatNullAsEmptyString
> -------------------------------------------
>
>                 Key: SPARK-59477
>                 URL: https://issues.apache.org/jira/browse/SPARK-59477
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 4.2.0
>            Reporter: Dejan Krakovic
>            Assignee: Dejan Krakovic
>            Priority: Major
>              Labels: pull-request-available
>
> Adds a per-write CSV option {{treatNullAsEmptyString}} that overrides the 
> session-level {{spark.sql.legacy.nullValueWrittenAsQuotedEmptyStringCsv}} 
> config for a single write.
> When set to false, nulls are written as a bare, unquoted empty token while 
> empty strings stay quoted ({{{}""{}}}), so downstream consumers can 
> differentiate null from an empty string. When set to true, nulls are written 
> as the {{{}emptyValue{}}}. When unset, the session config decides the 
> behavior, so existing writes are unaffected.
> This lets a workload opt into the differentiation without changing the 
> session/workspace default.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to