exportAsWorkSheet

fun exportAsWorkSheet(resultSet: ResultSet, sheet: Sheet, writeHeader: Boolean = true)

Exports the data in the ResultSet to an Excel worksheet. The ResultSet is assumed to be forward only and each row is processed until all rows are exported. The ResultSet is closed after the processing.

Parameters

resultSet

the result set to copy from

sheet

the sheet in the workbook to hold the results set values

writeHeader

whether to write a header of the column names into the sheet. The default is true