Here is the spark DataFrame I want to save as a csv.
type(MyDataFrame)
--Output: <class 'pyspark.sql.dataframe.DataFrame'>
To save this as a CSV, I have the following code:
MyDataFrame.write.csv(csv_path, mode = 'overwrite', header = 'true')
When I save this, the file name is something like this:
part-0000-766dfdf-78fg-aa44-as3434rdfgfg-c000.csv
Is there a way I can give this a custom name while saving it? Like "MyDataFrame.csv"