Bug 51356 - autoSizeColumn in SXSSF-Sheet
Summary: autoSizeColumn in SXSSF-Sheet
Alias: None
Product: POI
Classification: Unclassified
Component: SXSSF (show other bugs)
Version: 3.8-dev
Hardware: PC All
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
Depends on:
Reported: 2011-06-10 22:24 UTC by Roland Speckmeier
Modified: 2011-06-11 18:21 UTC (History)
0 users

Test Class for the AutoSizeColumn-Problem in SXXFS-Sheet (1.44 KB, application/octet-stream)
2011-06-11 10:12 UTC, Roland Speckmeier

Note You need to log in before you can comment on or make changes to this bug.
Description Roland Speckmeier 2011-06-10 22:24:34 UTC
In the SXSSF-Sheet the autoSizeColumn-Method doesn't work.
Comment 1 David Fisher 2011-06-11 00:28:55 UTC
Given the fact that SXSSF works on a sliding window on the file this is not surprising.

To make it work will likely require multiple passes - or some type of indication of intent.

Please show us how you are invoking it in code in a simple example.

Comment 2 Roland Speckmeier 2011-06-11 10:12:56 UTC
Created attachment 27146 [details]
Test Class for the AutoSizeColumn-Problem in SXXFS-Sheet
Comment 3 Yegor Kozlov 2011-06-11 18:21:54 UTC
Fixed in r1134721

Strictly speaking, auto-sizing of columns cannot be supported in SXSSF becasue as Dave pointed, this API can only access rows within the sliding window. I changed SXSSF so that it calculates column size for rows in memory, that is, column size is calculated for rows in the sling window. The result can be "off", but it is the best I can do.