Is there a limit for rows and columns writing to Excel from a Java PX?

I have a Java PX that creates an xlsx file using Apache POI. The PX finishes successfully but when I tried to open some of the larger files, I receive and warning “Excel found unreadable context in ‘FILENAME’. Do you want to recover the contents of this workbook? If you trust the source of this workbook,click Yes’. If I click Yes, the file would open but all formatting is gone.

My Excel file has 73 column and it looks like if I write more then 896 rows, the warning would be displayed. I did another test with a file having 35 columns and I was able to write approximately 1,860 rows. Both scenarios equate to around 65,000 cells. 

Has anyone else encountered this issue? If so, how would I resolve this?

Add Comment
1 Answer(s)

I don’t know about limits of POI, but you MUST use XLSX extension to hold large content. If Excel cannot handle that, generate CSV file and have non Excel app process that -> such as using Python based pandas

Agile Talent Answered on March 23, 2019.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.