mondrian.olap.MondrianException: Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )'

Pentaho BI Platform Tracking | Sulaiman Karmali | 4 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

    If I create a new report and select an analysis data-source and set the analysis file to steelwheels.mondrian.xml, select SampleData for connection and enter the sample query (see PRD-4027 for sample query), I get the following exception: ERROR] ExceptionDialog - ExceptionDialog.ERROR_0001 - UserError <org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed to create datasource:Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )'>org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed to create datasource:Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )' at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractMDXDataFactory.performQuery(AbstractMDXDataFactory.java:587) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractNamedMDXDataFactory.performQuery(AbstractNamedMDXDataFactory.java:145) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.BandedMDXDataFactory.queryData(BandedMDXDataFactory.java:54) at org.pentaho.reporting.ui.datasources.mondrian.MondrianPreviewWorker.run(MondrianPreviewWorker.java:99) at java.lang.Thread.run(Thread.java:680) ParentException: mondrian.olap.MondrianException: Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )' at mondrian.resource.MondrianResource$_Def0.ex(MondrianResource.java:947) at mondrian.olap.ConnectionBase.parseStatement(ConnectionBase.java:100) at mondrian.rolap.RolapConnection.parseStatement(RolapConnection.java:765) at mondrian.olap.ConnectionBase.parseQuery(ConnectionBase.java:55) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractMDXDataFactory.performQuery(AbstractMDXDataFactory.java:444) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractNamedMDXDataFactory.performQuery(AbstractNamedMDXDataFactory.java:145) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.BandedMDXDataFactory.queryData(BandedMDXDataFactory.java:54) at org.pentaho.reporting.ui.datasources.mondrian.MondrianPreviewWorker.run(MondrianPreviewWorker.java:99) at java.lang.Thread.run(Thread.java:680) Caused by: mondrian.olap.MondrianException: Mondrian Error:Internal error: While parsing set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) ) at mondrian.resource.MondrianResource$_Def0.ex(MondrianResource.java:947) at mondrian.olap.Util.newInternal(Util.java:2261) at mondrian.olap.Util.newError(Util.java:2277) at mondrian.parser.JavaccParserValidatorImpl.convertException(JavaccParserValidatorImpl.java:110) at mondrian.parser.JavaccParserValidatorImpl.parseInternal(JavaccParserValidatorImpl.java:59) at mondrian.olap.ConnectionBase.parseStatement(ConnectionBase.java:96) ... 7 more Caused by: mondrian.olap.MondrianException: Mondrian Error:Syntax error at line 1, column 1, token 'set' at mondrian.parser.JavaccParserValidatorImpl.convertException(JavaccParserValidatorImpl.java:99) ... 9 more

    Pentaho BI Platform Tracking | 4 years ago | Sulaiman Karmali
    mondrian.olap.MondrianException: Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )'
  2. 0

    If I create a new report and select an analysis data-source and set the analysis file to steelwheels.mondrian.xml, select SampleData for connection and enter the sample query (see PRD-4027 for sample query), I get the following exception: ERROR] ExceptionDialog - ExceptionDialog.ERROR_0001 - UserError <org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed to create datasource:Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )'>org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed to create datasource:Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )' at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractMDXDataFactory.performQuery(AbstractMDXDataFactory.java:587) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractNamedMDXDataFactory.performQuery(AbstractNamedMDXDataFactory.java:145) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.BandedMDXDataFactory.queryData(BandedMDXDataFactory.java:54) at org.pentaho.reporting.ui.datasources.mondrian.MondrianPreviewWorker.run(MondrianPreviewWorker.java:99) at java.lang.Thread.run(Thread.java:680) ParentException: mondrian.olap.MondrianException: Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )' at mondrian.resource.MondrianResource$_Def0.ex(MondrianResource.java:947) at mondrian.olap.ConnectionBase.parseStatement(ConnectionBase.java:100) at mondrian.rolap.RolapConnection.parseStatement(RolapConnection.java:765) at mondrian.olap.ConnectionBase.parseQuery(ConnectionBase.java:55) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractMDXDataFactory.performQuery(AbstractMDXDataFactory.java:444) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractNamedMDXDataFactory.performQuery(AbstractNamedMDXDataFactory.java:145) at org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.BandedMDXDataFactory.queryData(BandedMDXDataFactory.java:54) at org.pentaho.reporting.ui.datasources.mondrian.MondrianPreviewWorker.run(MondrianPreviewWorker.java:99) at java.lang.Thread.run(Thread.java:680) Caused by: mondrian.olap.MondrianException: Mondrian Error:Internal error: While parsing set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) ) at mondrian.resource.MondrianResource$_Def0.ex(MondrianResource.java:947) at mondrian.olap.Util.newInternal(Util.java:2261) at mondrian.olap.Util.newError(Util.java:2277) at mondrian.parser.JavaccParserValidatorImpl.convertException(JavaccParserValidatorImpl.java:110) at mondrian.parser.JavaccParserValidatorImpl.parseInternal(JavaccParserValidatorImpl.java:59) at mondrian.olap.ConnectionBase.parseStatement(ConnectionBase.java:96) ... 7 more Caused by: mondrian.olap.MondrianException: Mondrian Error:Syntax error at line 1, column 1, token 'set' at mondrian.parser.JavaccParserValidatorImpl.convertException(JavaccParserValidatorImpl.java:99) ... 9 more

    Pentaho BI Platform Tracking | 4 years ago | Sulaiman Karmali
    mondrian.olap.MondrianException: Mondrian Error:Failed to parse query 'set [TopSelection] as 'TopCount(FILTER([Customers].[All Customers].Children,[Measures].[Sales]>0), Parameter("TopCount", NUMERIC, 10, "Number of Customers to show"), [Measures].[Sales])' Member [Customers].[All Customers].[Total] as 'Sum([TopSelection])' Member [Customers].[All Customers].[Other Customers] as '[Customers].[All Customers] - [Customers].[Total]' select NON EMPTY {[Measures].[Sales],[Measures].[Quantity] } ON COLUMNS, { [TopSelection], [Customers].[All Customers].[Other Customers]} ON ROWS from [SteelWheelsSales] where ( strToMember(Parameter("sLine", STRING, "[Product].[All Products].[Classic Cars]")), strToMember(Parameter("sMarket", STRING, "[Markets].[All Markets].[Japan]")), strToMember(Parameter("sYear", STRING, "[Time].[All Years].[2003]")) )'

    Root Cause Analysis

    1. mondrian.olap.MondrianException

      Mondrian Error:Syntax error at line 1, column 1, token 'set'

      at mondrian.parser.JavaccParserValidatorImpl.convertException()
    2. mondrian.parser
      JavaccParserValidatorImpl.parseInternal
      1. mondrian.parser.JavaccParserValidatorImpl.convertException(JavaccParserValidatorImpl.java:99)
      2. mondrian.parser.JavaccParserValidatorImpl.parseInternal(JavaccParserValidatorImpl.java:59)
      2 frames
    3. mondrian.olap
      ConnectionBase.parseStatement
      1. mondrian.olap.ConnectionBase.parseStatement(ConnectionBase.java:96)
      1 frame
    4. mondrian.rolap
      RolapConnection.parseStatement
      1. mondrian.rolap.RolapConnection.parseStatement(RolapConnection.java:765)
      1 frame
    5. mondrian.olap
      ConnectionBase.parseQuery
      1. mondrian.olap.ConnectionBase.parseQuery(ConnectionBase.java:55)
      1 frame
    6. org.pentaho.reporting
      MondrianPreviewWorker.run
      1. org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractMDXDataFactory.performQuery(AbstractMDXDataFactory.java:444)
      2. org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.AbstractNamedMDXDataFactory.performQuery(AbstractNamedMDXDataFactory.java:145)
      3. org.pentaho.reporting.engine.classic.extensions.datasources.mondrian.BandedMDXDataFactory.queryData(BandedMDXDataFactory.java:54)
      4. org.pentaho.reporting.ui.datasources.mondrian.MondrianPreviewWorker.run(MondrianPreviewWorker.java:99)
      4 frames
    7. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:680)
      1 frame