MaxGekk opened a new pull request #25182: [SPARK-27609][PYTHON] Convert values 
of function options to strings
URL: https://github.com/apache/spark/pull/25182
 
 
   ## What changes were proposed in this pull request?
   
   In the PR, I propose to convert options values to strings by using 
`to_str()` for the following functions:  `from_csv()`, `to_csv()`, 
`from_json()`, `to_json()`, `schema_of_csv()` and `schema_of_json()`. This will 
make handling of function options consistent to option handling in 
`DataFrameReader`/`DataFrameWriter`.
   
   For example:
   ```Python
   df.select(from_csv(df.value, "s string", {'ignoreLeadingWhiteSpace': True})
   ```
   
   ## How was this patch tested?
   
   Added an example for `from_csv()` which was tested by:
   ```Shell
   ./python/run-tests --testnames pyspark.sql.functions
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to