Skip to content

Add sheet name selection to Excel readers - #218

Open
Adrastopoulos wants to merge 1 commit into
spring-projects:mainfrom
Adrastopoulos:gabriel/excel-sheet-selection
Open

Add sheet name selection to Excel readers#218
Adrastopoulos wants to merge 1 commit into
spring-projects:mainfrom
Adrastopoulos:gabriel/excel-sheet-selection

Conversation

@Adrastopoulos

@Adrastopoulos Adrastopoulos commented Aug 26, 2026

Copy link
Copy Markdown

Changes

Add setSheetNames(String...) to AbstractExcelItemReader.

Default behavior remains the same...

When names are configured, it skips non-matching sheets before creating a RowSet, so skipped-row callbacks and row mapping run only for selected sheets. Multiple configured names still follow workbook order. This works for both PoiItemReader and the streaming readers because selection happens in the abstract reader lifecycle.

Tests

SheetSelectionTests covers the default, multiple selected names in workbook order, and no match.

Closes #95

Signed-off-by: Gabriel Hall <gabriel.hall@cox.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Need of reading one particular sheet.

2 participants