1

I have been using Spark-excel (https://github.com/crealytics/spark-excel) to write the output to a single sheet of an Excel sheet. However, I am unable to write the output to different sheets (tabs).

Can anyone suggest any alternative?

Thanks, Sai

baitmbarek
  • 2,440
  • 4
  • 18
  • 26
Bharath
  • 467
  • 2
  • 8
  • 20
  • Can't you just split your data into several tables and save each other separately while specifying a different `sheetName` parameter? – ktdrv Feb 23 '18 at 23:26
  • I tried that.The data gets overwritten since this supports only overwrite in the save mode. – Bharath Feb 26 '18 at 14:48

1 Answers1

0

I would suggest to split the problem into two phases:

  1. save the data into multiple csv using multiple Spark flows
  2. write an application, that converts multiple csv files to a single excel sheet, using e.g. this Java library: http://poi.apache.org/
wind
  • 892
  • 1
  • 11
  • 27