posted 13 years ago
Rohit,
I am not 100% familiar with the Apache POI API, however is it possible to read only a limited number of records at a time, then resume reading? Separating a single file into batches of records should help improve your overall memory consumption.
In other words, you can first read the first 5000 records and perform whatever processing you require. Then read the next 5000 records, etc . . .
Hope this provides some insight.
Regards,
Anthony