org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day.

Pentaho BI Platform Tracking | Will Gorman | 8 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Attached is a simple example. I added a few days worth of data, and it works fine if the time series time-period-type is Day, but if its anything else I get the following stack exception: org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day. at org.jfree.data.time.TimeSeries.add(TimeSeries.java:497) at org.jfree.data.time.TimeSeries.add(TimeSeries.java:473) at org.pentaho.plugin.jfreereport.reportcharts.collectors.TimeSeriesCollector.buildDataset(TimeSeriesCollector.java:188) at org.pentaho.plugin.jfreereport.reportcharts.collectors.AbstractCollectorFunction.itemsAdvanced(AbstractCollectorFunction.java:230) at org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireItemsAdvancedEvent(ExpressionDataRow.java:714) 18:11:34,312 ERROR [ExpressionDataRow] Failed to fire prepare event: org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day. at org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireReportEvent(ExpressionDataRow.java:568) at org.pentaho.reporting.engine.classic.core.states.datarow.GlobalMasterRow.fireReportEvent(GlobalMasterRow.java:558) at org.pentaho.reporting.engine.classic.core.states.datarow.DefaultFlowController.fireReportEvent(DefaultFlowController.java:410) at org.pentaho.reporting.engine.classic.core.states.process.ProcessState.fireReportEvent(ProcessState.java:962) at org.pentaho.reporting.engine.classic.core.states.process.ProcessDetailsHandler.advance(ProcessDetailsHandler.java:59) at org.pentaho.reporting.engine.classic.core.states.process.ProcessState.advance(ProcessState.java:780) at org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.processPrepareLevels(AbstractReportProcessor.java:345) at org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.prepareReportProcessing(AbstractReportProcessor.java:445) at org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.PrintReportProcessor.getNumberOfPages(PrintReportProcessor.java:90) at org.pentaho.reporting.engine.classic.core.modules.gui.base.PreviewPane$RepaginationRunnable.run(PreviewPane.java:274) at org.pentaho.reporting.engine.classic.core.util.Worker.run(Worker.java:187)

    Pentaho BI Platform Tracking | 8 years ago | Will Gorman
    org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day.
  2. 0

    Attached is a simple example. I added a few days worth of data, and it works fine if the time series time-period-type is Day, but if its anything else I get the following stack exception: org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day. at org.jfree.data.time.TimeSeries.add(TimeSeries.java:497) at org.jfree.data.time.TimeSeries.add(TimeSeries.java:473) at org.pentaho.plugin.jfreereport.reportcharts.collectors.TimeSeriesCollector.buildDataset(TimeSeriesCollector.java:188) at org.pentaho.plugin.jfreereport.reportcharts.collectors.AbstractCollectorFunction.itemsAdvanced(AbstractCollectorFunction.java:230) at org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireItemsAdvancedEvent(ExpressionDataRow.java:714) 18:11:34,312 ERROR [ExpressionDataRow] Failed to fire prepare event: org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day. at org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireReportEvent(ExpressionDataRow.java:568) at org.pentaho.reporting.engine.classic.core.states.datarow.GlobalMasterRow.fireReportEvent(GlobalMasterRow.java:558) at org.pentaho.reporting.engine.classic.core.states.datarow.DefaultFlowController.fireReportEvent(DefaultFlowController.java:410) at org.pentaho.reporting.engine.classic.core.states.process.ProcessState.fireReportEvent(ProcessState.java:962) at org.pentaho.reporting.engine.classic.core.states.process.ProcessDetailsHandler.advance(ProcessDetailsHandler.java:59) at org.pentaho.reporting.engine.classic.core.states.process.ProcessState.advance(ProcessState.java:780) at org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.processPrepareLevels(AbstractReportProcessor.java:345) at org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.prepareReportProcessing(AbstractReportProcessor.java:445) at org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.PrintReportProcessor.getNumberOfPages(PrintReportProcessor.java:90) at org.pentaho.reporting.engine.classic.core.modules.gui.base.PreviewPane$RepaginationRunnable.run(PreviewPane.java:274) at org.pentaho.reporting.engine.classic.core.util.Worker.run(Worker.java:187)

    Pentaho BI Platform Tracking | 8 years ago | Will Gorman
    org.jfree.data.general.SeriesException: You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day.

    Root Cause Analysis

    1. org.jfree.data.general.SeriesException

      You are trying to add data where the time period class is org.jfree.data.time.Week, but the TimeSeries is expecting an instance of org.jfree.data.time.Day.

      at org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireReportEvent()
    2. org.pentaho.reporting
      Worker.run
      1. org.pentaho.reporting.engine.classic.core.states.datarow.ExpressionDataRow.fireReportEvent(ExpressionDataRow.java:568)
      2. org.pentaho.reporting.engine.classic.core.states.datarow.GlobalMasterRow.fireReportEvent(GlobalMasterRow.java:558)
      3. org.pentaho.reporting.engine.classic.core.states.datarow.DefaultFlowController.fireReportEvent(DefaultFlowController.java:410)
      4. org.pentaho.reporting.engine.classic.core.states.process.ProcessState.fireReportEvent(ProcessState.java:962)
      5. org.pentaho.reporting.engine.classic.core.states.process.ProcessDetailsHandler.advance(ProcessDetailsHandler.java:59)
      6. org.pentaho.reporting.engine.classic.core.states.process.ProcessState.advance(ProcessState.java:780)
      7. org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.processPrepareLevels(AbstractReportProcessor.java:345)
      8. org.pentaho.reporting.engine.classic.core.layout.output.AbstractReportProcessor.prepareReportProcessing(AbstractReportProcessor.java:445)
      9. org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.PrintReportProcessor.getNumberOfPages(PrintReportProcessor.java:90)
      10. org.pentaho.reporting.engine.classic.core.modules.gui.base.PreviewPane$RepaginationRunnable.run(PreviewPane.java:274)
      11. org.pentaho.reporting.engine.classic.core.util.Worker.run(Worker.java:187)
      11 frames