Exporting to Excel Output Format Throws ArrayIndexOutOfBoundsException When There Are More Data Columns Than Defined in the Header
(Doc ID 2900322.1)
Last updated on OCTOBER 10, 2022
Applies to:
BI Publisher (formerly XML Publisher) - Version 12.2 and laterInformation in this document applies to any platform.
Symptoms
When using template/data combination that can generate more number of data columns than columns defined in table header, XLSX output throws ArrayIndexOutOfBoundsException. The same error won't be seen for other output types like PDF and HTML.
Steps
- Create an RTF template which has a simple Word table with 2 rows and 46 columns. The first row will be used for the header and the second row will be populated dynamically based on loops.
- Add 46 columns for the header row. No programming is used for the header row.
- In the first column of the second row, enter a for-each-group loop.
- In a different column of the same row, enter another for-each-group loop.
- In the last column of the same row, end both for-each-group loops.
- Create a report based on the RTF template created above and using an XML Data with information that will require the second for-each-group to run more than once. This will add additional columns for some rows.
- Run the report.
- Export the report to HTML, PDF, PPT.
- Verify the report is generated successfully.
- Export the report to Excel.
- Verify the java.lang.ArrayIndexOutOfBoundsException: 46 >= 46 occurs.
Changes
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Changes |
Cause |
Solution |
References |