• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

CFSpreadsheet fails to read atleast one row if the excel file size is big

New Here ,
Feb 28, 2017 Feb 28, 2017

Copy link to clipboard

Copied

CFSpreadsheet fails to read atleast one row if the excel file size is big. I am trying to read a excel file of size say 20mb. But it is giving java heap space error when reading the whole file. But when I specify the row attribute, it is not able to read even one row from the big file. Please help me on this issue.

Views

856

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Mar 01, 2017 Mar 01, 2017

Copy link to clipboard

Copied

How much memory on the server and how much memory is CF / JVM configured to use?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Mar 01, 2017 Mar 01, 2017

Copy link to clipboard

Copied

Minimum JVM Heap Size (in 256 MB)   Maximum JVM Heap Size (in 1024 MB)    . I am trying to do it in CF2016 developer edition. I tested it in my dev server with higher configuration as well. same behaviour.

Server Details
Server Product ColdFusion 2016
Version 2016.0.03.300466
Tomcat Version 8.0.32.0
Edition Developer  
Operating System Windows 10  
OS Version 10.0  
Update Level C:/ColdFusion2016/cfusion/lib/updates/chf20160003.jar  
Adobe Driver Version 5.1.4 (Build 0001) 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Mar 06, 2017 Mar 06, 2017

Copy link to clipboard

Copied

LATEST

The memory problem in cfspreadsheet has been known for some time. Most of ColdFusion's spreadsheet functionality is based on the POI library. The version of POI which ColdFusion implements is the User API. This loads the entire document into memory. That is what causes the out-of-memory error when you read a large Excel file.

I am sorry to say, I don't think there is currently any way to work around this problem in ColdFusion. Nevertheless, there are two possible solutions, in Java, also provided by Apache POI, namely its Event API or Streaming Usermodel API.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation