Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

225
Views
Procesing big excel file with nodejs in SAP S/4Hana Application

I would like to ask for some help with solving the problem I'm facing (not a javascript developer, bare in mind. ). Any help would be grateful.

  • Process: User uploads selected excel file from UI. In back-end we process file with xlsx/exceljs javascirpt libraries (tried both - same end result) to populate custom data structures for later uses.

  • Problem: with big excel files (from 10k rows and more, with lots of attributes) I get following error:

    ...Error: Corrupted zip: can't find end of central directory.

  • Additional info: by running the same code on plain nodejs server (locally) - it works. On SAP server - it doesn't. With small files - all good.

  • Tech: SAP S/4Hana, OData v4, xlsx v0.18.5, exceljs v4.3.0, node >=v12.

  • Code example:

     //with exceljs library
     fromXlsx_1: async (buffer, cols) => {
    
     const workbook = new ExcelJS.Workbook();
     await workbook.xlsx.load(buffer);//<-- error
    
     workbook.worksheets.forEach(function(sheet) {
    
         //some code
    
         });
    
    },
    //with xlsx library
    fromXlsx_2: (buffer, cols) => {
         var book = XLSX.read(buffer, { type: 'buffer', cellDates: true, cellText: false);//<-- error
         var sheet = book.Sheets[book.SheetNames[0]];
         const result = XLSX.utils.sheet_to_json(sheet, { header: Object.entries(cols).map(a => a[0]), raw: true });
    
         //some code
    }
    

If more information is needed- ask away. Thank you for your time.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Managed to solve it. The root cause were - lack of knowledge and the implementation of package "busboy" (made a presumption, that colleagues, that wrote the custom package to "process" files, did not make a mistake). If you stumble on similar problem like me, double check the "busboy" implementation, if its parsing the file correctly and it WAITS for the the file to be processed all - with async/await concept.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!