Skip to content

Commit

Permalink
Update README.adoc
Browse files Browse the repository at this point in the history
Include a FAQ section for commonly asked questions. 

Closes: #97
  • Loading branch information
mdeinum authored Oct 2, 2023
1 parent 8a276f9 commit 7efdb20
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions spring-batch-excel/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,16 @@ Uses a `BeanWrapper` to convert a given row into an object. Uses the column name
</property>
</bean>
----

== Frequently Asked Questions

=== Not able to open large Excel
When opening large Excel files or Excel files with large amounts of data in a single cell it might fail with an error

```
"Unexpected error Tried to allocate an array of length 162,386,364, but the maximum length for this record type is 100,000,000. If the file is not corrupt or large, please open an issue on bugzilla to request increasing the maximum allowable size for this record type. As a temporary workaround, consider setting a higher override value with IOUtils.setByteArrayMaxOverride()"
```

This is due to the maximum lenght for certain datatypes is limited. To prevent this from happening you can use the `IOUtils.setByteArrayMaxOverride()` method to increase the allowed size. It is however important that this is set before anything POI related has been processed/configured.

Ideally, when using Spring Boot, you can set this before launching the application or by putting this in a `static {}` initializer block of the Spring Batch job configuration.

0 comments on commit 7efdb20

Please sign in to comment.