Uploaded image for project: 'ZK Spreadsheet'
  1. ZK Spreadsheet
  2. ZSS-341

2 statistical formulas throw NotImplementedException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 3.0.0 RC
    • 2.5.0, 3.0.0 RC
    • ZSS Component

      problem description:

      error evaluating formulas:
      AVERAGEIF, AVERAGEIFS

      java.lang.AssertionError: =AVERAGEIF(B12:E12,"<23000") failed, at row 11 in xsheet: formula-statistical
      Expected: "14000"
           but: was "Error evaluating cell 'formula-statistical'!B11"
      
      

      Exception stack trace:

       >>org.zkoss.poi.ss.formula.eval.NotImplementedException: Error evaluating cell 'formula-statistical'!B11
      >>org.zkoss.poi.ss.formula.eval.NotImplementedException: AVERAGEIF
      >>	at org.zkoss.poi.ss.formula.atp.AnalysisToolPak$NotImplemented.evaluate(AnalysisToolPak.java:40)
      >>	at org.zkoss.poi.ss.formula.UserDefinedFunction.evaluate(UserDefinedFunction.java:65)
      >>	at org.zkoss.poi.ss.formula.OperationEvaluatorFactory.evaluate(OperationEvaluatorFactory.java:129)
      >>	at org.zkoss.poi.ss.formula.WorkbookEvaluator.evaluateFormula(WorkbookEvaluator.java:539)
      >>	at org.zkoss.poi.ss.formula.WorkbookEvaluator.evaluateAny(WorkbookEvaluator.java:316)
      >>	at org.zkoss.poi.ss.formula.WorkbookEvaluator.evaluate(WorkbookEvaluator.java:255)
      >>	at org.zkoss.poi.xssf.usermodel.XSSFFormulaEvaluator.evaluateFormulaCellValue(XSSFFormulaEvaluator.java:266)
      >>	at org.zkoss.poi.xssf.usermodel.XSSFFormulaEvaluator.evaluate(XSSFFormulaEvaluator.java:119)
      >>	at org.zkoss.zss.model.sys.impl.BookHelper.evaluate(BookHelper.java:476)
      >>	at org.zkoss.zss.model.sys.impl.BookHelper.getFormatText(BookHelper.java:1018)
      >>	at org.zkoss.zss.ui.impl.XUtils.getFormatText(XUtils.java:355)
      >>	at org.zkoss.zss.ui.impl.CellFormatHelper.getHtmlStyle(CellFormatHelper.java:89)
      >>	at org.zkoss.zss.ui.Spreadsheet$ExtraCtrl.getCellAttr(Spreadsheet.java:3066)
      >>	at org.zkoss.zss.ui.Spreadsheet$ExtraCtrl.getRangeAttrs(Spreadsheet.java:2940)
      >>	at org.zkoss.zss.ui.Spreadsheet.updateSheetAttributes(Spreadsheet.java:859)
      >>	at org.zkoss.zss.ui.Spreadsheet.setSelectedSheetDirectly(Spreadsheet.java:798)
      >>	at org.zkoss.zss.ui.Spreadsheet.access$40(Spreadsheet.java:776)
      >>	at org.zkoss.zss.ui.Spreadsheet$ExtraCtrl.setSelectedSheetDirectly(Spreadsheet.java:3520)
      >>	at org.zkoss.zss.ui.au.in.SelectSheetCommand.process(SelectSheetCommand.java:87)
      >>	at org.zkoss.zss.ui.Spreadsheet.service(Spreadsheet.java:4721)
      
      

      reproducing steps

      run automatic test case FormulaTest of the project zss.test of zkspreadsheet or attached file

            hawk hawk
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: