I have to read large sized xlsm with low memory footprint and since apache POI provides XSSF SAX, I should prefer using it. In the first sheet from existing xlsm parsed with SAX, i need to append some data from db and write it out as another xlsm. SXSSF provides streaming write and hence should combine both SAX read and SXSSF write. By this way i think heap size problem can be avoided for large size.
Is this possible using POI or are there any other approach ?
Kindly suggest me on this approach with any example !
Asked
Active
Viewed 1,463 times
0

Sva
- 115
- 1
- 12
-
hey, i have a similar problem. were you able to resolve your issue. I am curious to know what approach you used. – Ash Jun 06 '14 at 20:06
-
I was unable to achieve the read using XSSF SAX and write with SXSSF.. Instead moved to Aspose.cells which was able to manipulate huge data with xlsb format that drastically reduces file size.. – Sva Jun 09 '14 at 12:50
1 Answers
1
Based on the POI Spreadsheet Feature table, you cannot read files with SXSSF buffered streaming, although SXSSF buffered streaming does have the ability to write files.
My suggestion would be to read, parsing with SAX, using the XSSF eventmodel, and then write out using SXSSF buffered streaming to write the new file.

Robert Gannon
- 253
- 4
- 13