[Mondrian] about parseQuery()
Yang Guo
blizzaaard at gmail.com
Thu Mar 31 13:04:29 EDT 2011
I am trying to create a Query object from a string, like this:
// Load the driver
Class.forName("mondrian.olap4j.MondrianOlap4jDriver");
// Connect
final Connection connection =
DriverManager.getConnection(
"jdbc:mondrian:"
+ "JdbcDrivers=com.mysql.jdbc.Driver;"
+ "Jdbc=jdbc:mysql://***:3306/***?user=***&password=***;"
+ "Catalog=file:***.xml;");
// We are dealing with an olap connection. we must unwrap it.
final OlapConnection olapConnection =
connection.unwrap(OlapConnection.class);
// Get a cube object.
Cube peopleCube = olapConnection.getSchema().getCubes().get("People"
);
Query myQuery = connection.parseQuery("SELECT ...");
It said there is no parseQuery() here:
groovy.lang.MissingMethodException: No signature of method:
mondrian.olap4j.FactoryJdbc4Impl$MondrianOlap4jConnectionJdbc4.parseQuery()
is applicable for argument types: (java.lang.String) values: [SELECT ...]
How do I use parseQuery()?
Best,
--
Yang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.pentaho.org/pipermail/mondrian/attachments/20110331/11e54719/attachment.html
More information about the Mondrian
mailing list