Jump to content

Data split into two rows when exporting to xls


dh33b4n

Recommended Posts

When trying to export a SQL query result to xls the data is split into 2 rows,
 

I am using jasperreports 6.3.0 version
 

These are the export paramters used:

xlsExporter.setParameter(JRXlsExporterParameter.SHEET_NAMES, new String[]{sheetNames});

xlsExporter.setParameter(JRXlsExporterParameter.IS_DETECT_CELL_TYPE,Boolean.TRUE);

xlsExporter.setParameter(JRXlsExporterParameter.IS_ONE_PAGE_PER_SHEET, Boolean.FALSE);

xlsExporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_COLUMNS,Boolean.TRUE);

xlsExporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS,Boolean.TRUE);

xlsExporter.setParameter(JRXlsExporterParameter.IS_WHITE_PAGE_BACKGROUND, Boolean.FALSE);

xlsExporter.setParameter(JRXlsExporterParameter.MAXIMUM_ROWS_PER_SHEET, 65535);

xlsExporter.setParameter(JRXlsExporterParameter.IS_IGNORE_GRAPHICS, Boolean.TRUE);

xlsExporter.setParameter(JRXlsExporterParameter.CHARACTER_ENCODING,"UTF-8");

 

When a result of SQL query below is exported I get result like in table at row_number 198
the row gets split to 2 rows, and this repeates at row_number  297, 396 ..
SELECT row_number() over(),'1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890' AS column1 FROM Table1

1row_numbercolumn1
1981971234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
1991981234567890123456789012345678901234567890123456789012345678901234567890
200198123456789012345678901234567890

Can anybody please tell what might be causing this issue

Thank you

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic


Thank you for posting to the Jaspersoft Community. Our team of experts has read your question and we are working to get you an answer as quickly as we can. If you have a Jaspersoft Professional Subscription plan, please visit https://support.tibco.com/s/ for direct access to our technical support teams offering guaranteed response times.

Link to comment
Share on other sites

  • 2 weeks later...

Are you saying that in your output table, the two rows identified by "row_number = 198" should be returning on the one row? And it repeats the behavior every 99 rows? That could possibly be a bug - you are using a very old version of JRS, is there any way for you to update to a later version to at least test? You can pretty easily install the latest community version (i.e. free) to your machine with our bundled installer and test your report there.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...