processLargeFile.withStreamingOptions() #415
Replies: 2 comments 1 reply
-
Sorry but I'm not sure what you mean by that. ProcessLargeFile() doesn't return any data, it just runs your row processing function over each row as it's streamed from disk. What does your row processing function look like? If it takes each row and adds it to a variable, then obviously that will end up containing the entire sheet data, which case you're probably better off with readLargeFile(). |
Beta Was this translation helpful? Give feedback.
-
I wonder if you've misunderstood the purpose of If you are wanting to read your sheet into smaller chunks that your application can then work with, then you could write your processor function to process the rows in batches. Here's an example:
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi. I can't get processLargeFile to use rowCacheSize. The entire sheet is being returned. Am I missing something? Even if I remove it, I get the whole sheet and not the 10 row default. Thank you.
options = {
bufferSize: 2048,
rowCacheSize: 25
}
variables.spreadsheet.processLargeFile(variables.filepath)
.withRowProcessor( processor )
.withStreamingOptions( options )
.withSheetName( "age_breed_group_map" )
.withFirstRowIsHeader()
.execute();
Beta Was this translation helpful? Give feedback.
All reactions