0

am trying to write xml file from my dataframe like below

 myDf.orderBy("name")
.repartition(1).write
.format("com.databricks.spark.xml)
.option("rootTag","colname")
.option("rowTag","colname2")
.save("filename")

This is writing a file but not following the order I specify. Every-time it gives different random order. How to get ordering proper in spark XML writing

Nikunj Kakadiya
  • 2,689
  • 2
  • 20
  • 35
Karthik
  • 1
  • 1

0 Answers0