You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2003/06/24 16:37:16 UTC

DO NOT REPLY [Bug 21049] New: - Cannot Instantiate HSSFWorkBook on large excel document

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21049>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21049

Cannot Instantiate HSSFWorkBook on large excel document

           Summary: Cannot Instantiate HSSFWorkBook on large excel document
           Product: POI
           Version: unspecified
          Platform: Sun
        OS/Version: Solaris
            Status: NEW
          Severity: Critical
          Priority: Other
         Component: HSSF
        AssignedTo: poi-dev@jakarta.apache.org
        ReportedBy: gnangoma@hotmail.com


The HSSFWorkBook construct throws exception when trying to instantiate an excel 
workbook from a large excel document. Specifically, the document has more than 
14,000 rows. 
When reducing the number of rows to ~7,000 no exception is thrown. Must be 
something to do with the number of rows.

Below is the exception:
java.lang.reflect.InvocationTargetException: 
java.lang.ArrayIndexOutOfBoundsException
        at org.apache.poi.util.LittleEndian.getNumber(LittleEndian.java:557)
        at org.apache.poi.util.LittleEndian.getInt(LittleEndian.java:177)
        at org.apache.poi.hssf.record.BOFRecord.fillFields(BOFRecord.java:170)
        at org.apache.poi.hssf.record.Record.fillFields(Record.java:143)
        at org.apache.poi.hssf.record.Record.<init>(Record.java:105)
        at org.apache.poi.hssf.record.BOFRecord.<init>(BOFRecord.java:135)
        at java.lang.reflect.Constructor.newInstance(Native Method)
        at org.apache.poi.hssf.record.RecordFactory.createRecord
(RecordFactory.java:257)
        at org.apache.poi.hssf.record.RecordFactory.createRecords
(RecordFactory.java:193)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:199)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:166)
        at ExcelReader.main(ExcelReader.java:73)
Exception in thread "main" org.apache.poi.hssf.record.RecordFormatException: 
Unable to construct record instance, the following exception occured: null
        at org.apache.poi.hssf.record.RecordFactory.createRecord
(RecordFactory.java:270)
        at org.apache.poi.hssf.record.RecordFactory.createRecords
(RecordFactory.java:193)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:199)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:166)
        at ExcelReader.main(ExcelReader.java:73)