[Mondrian] RE: Mondrian - aggregate tables not being used in Foodmart schema

Radha Ranjan Madhaw RMadhaw at facetime.com
Tue Feb 19 00:42:27 EST 2008


Hi All,

 

I'm running the following query (provided in a sample program with
Mondrian distribution) against Foodmart schema.

SELECT {[Measures].[Unit Sales], [Measures].[Store Cost],
[Measures].[Store Sales]} ON 0, {[Product].Children} ON 1 FROM [Sales]

I set the trace on (using System.setProperty("mondrian.trace.level",
"1");) and I can't see the aggregate table agg_c_special_sales_fact_1997
being used in any of the generated SQL query. I'm using Foodmart.xml
(distributed with mondrian) as catalog file.

How do I make sure that a particular aggregate table is being used? I've
created the foodmart database schema in MySQL 5 using the
mondrian.test.loader.MondrianFoodMartLoader class and tested the MDX
query.

I executed the MDX query repeatedly (in a single execution of JVM), I
found that the first execution was ~1200 ms. However, subsequent
executions (in the same running JVM) were of the order of 5-10 ms, which
is because of caching done by Mondrian. Please let me know if I'm right.


However, the first execution takes so much time and also from the SQL
queries generated in the trace seems to suggest that there is some
problem and the aggregate table is not being used.

I've attached the java program which I'm using. Also, I'm using the
mondrian.jar available inside Olap4J jar distribution. When I tried
using mondrian.jar inside Mondrian distribution, I encountered following
error:

 

Exception in thread "Thread-0" java.lang.NoSuchMethodError:
mondrian.olap.Query.setQueryTimeoutMillis(J)V

      at
mondrian.olap4j.MondrianOlap4jCellSet.execute(MondrianOlap4jCellSet.java
:72)

      at
mondrian.olap4j.MondrianOlap4jStatement.executeOlapQueryInternal(Mondria
nOlap4jStatement.java:288)

      at
mondrian.olap4j.MondrianOlap4jStatement.executeOlapQuery(MondrianOlap4jS
tatement.java:258)

      at mondrian.OLAP4JTest$QueryPerfCheck.run(OLAP4JTest.java:61)

 

Please suggest me corrective actions.

 

Thanks in advance.

Regards,

Madhav

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.pentaho.org/pipermail/mondrian/attachments/20080219/4d84b1b1/attachment.html 


More information about the Mondrian mailing list