Writing large excel files causes out of memory in IE11 and web page crashes in chrome #540
Labels
No Label
DBF
Dates
Defined Names
Features
Formula
HTML
Images
Infrastructure
Integration
International
ODS
Operations
Performance
PivotTables
Pro
Protection
Read Bug
SSF
SYLK
Style
Write Bug
good first issue
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sheetjs/sheetjs#540
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hi,
I am trying to write an excel file from a 2D array. My array contains approximately 176000 records (total cells will be 176000 * 17, where 17 is column count). While writing IE11 gives Out of Memory in console and Chrome gives "Aw Snap" page saying "Chrome ran out of memory". One time it ran successfully to write the same data file and it's size came to be around 127MB.
Is there a different way of writing these kinds of large excel files? like as an stream.
I am using the same code provided in https://github.com/SheetJS/js-xlsx/blob/master/tests/write.js, apart from this I am using jszip.js and FileSaver.js for saving the file.
Same problem with 65000 records, any thoughts/ideas?
Not much, the code breaks in xlsx.js when jszip.js' generate function is called. I tried updating the code to use jszip's 3.x version, which has generateAsync function. Since I don't know much about web worker or StreamHelper I couldn't do anything with it.
Finally I dropped out of generating excel file, now I am just creating CSVs.
@rahulstomar consider a simple file of the form
For 176k rows and 17 columns, Excel 2016 for Windows generates files of the following sizes:
IMHO at this scale if you are just passing data you can't really beat the CSV.
Exposing the jszip compression option would reduce the file size but extend the processing time.
@alejandrolsca if generating large files is of particular interest, we would need a different approach. The Excel 2003 XML format is incredibly easy to stream as it does not involve any sort of post-processing, but has the downside of bloat. Generating an old form of XLS (e.g. BIFF2) would also have a small file size but you would not be able to open the file with all third-party programs.
I'm having the same issue. Quick googling gave me this Stuk/jszip#135.
Grouping large file write issues into #77