poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 56556] New: XSSFSheet.setColumnWidth performance issue caused by ColumnHelper.getColumn1Based
Date Fri, 23 May 2014 08:51:06 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=56556

            Bug ID: 56556
           Summary: XSSFSheet.setColumnWidth performance issue caused by
                    ColumnHelper.getColumn1Based
           Product: POI
           Version: 3.11-dev
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSSF
          Assignee: dev@poi.apache.org
          Reporter: xiao.xj@bigfoot.com

It tooks 4-5 minutes for 3K columns.

public class Excel2007ColumnSize extends TestCase {

    int TOTAL_COL = 3000;
    short WDITH = 15 * 255;

    public void testSetColumnSize() {
        Workbook wb = new XSSFWorkbook();
        Sheet st = wb.createSheet();
        Row row = st.createRow(0);
        System.out.println("1: " + System.currentTimeMillis());
        for (int i = 0; i < TOTAL_COL; i++) {
            st.setColumnWidth(i, WDITH);
        }
        System.out.println("2: " + System.currentTimeMillis());
    }
}

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Mime
View raw message