ID,Score1,Score2,Total Score
user021,4/4,2/2,14.0/50.0
The above csv which generated using spark dataframe.
df.coalesce(1).write
.mode("overwrite")
.format("com.databricks.spark.csv")
.option("header", "true")
.save(url)
When we open that CSV in the excel sheet for Score1 and Score2 columns are converted to Date formate.
Is there Any configurations to keep both column Score1 and Score2 as string formate instead of date formate?
Things which I tried but no luck!
df.coalesce(1).write
.mode("overwrite")
.format("com.databricks.spark.csv")
.option("header", "true")
.option("inferSchema", "false/true")
.save(url)
I tried with inferSchema
configuration but no luck in this.