Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: error in using olap4j to access pentaho xmla service

  1. #1
    Join Date
    Jun 2016
    Posts
    1

    Default error in using olap4j to access pentaho xmla service

    guys,
    I set up the pentaho xmla service. I think it is working well, for I can access it in excel:
    Name:  tmp001.jpg
Views: 235
Size:  15.5 KB

    but when i developed a java client, an error occur in line 6:
    1 try {
    2 Class.forName("org.olap4j.driver.xmla.XmlaOlap4jDriver");
    3 String connectString2="jdbc:xmla:Server=http://localhost:8080/pentaho/Xmla?catalog=FoodMart&userid=Admin&password=password";
    4 Connection cnx = DriverManager.getConnection(connectString2, null, null);
    5 OlapConnection olapConnection = cnx.unwrap(OlapConnection.class);
    6 olapConnection.setCatalog("FoodMart");
    ......


    the error is:
    java.lang.RuntimeException: [FATAL]:29:3: The element type "meta" must be terminated by the matching end-tag "</meta>".
    at org.olap4j.driver.xmla.XmlaOlap4jUtil.checkForParseError(XmlaOlap4jUtil.java:137)
    at org.olap4j.driver.xmla.XmlaOlap4jUtil.parse(XmlaOlap4jUtil.java:86)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.executeMetadataRequest(XmlaOlap4jConnection.java:887)
    at org.olap4j.driver.xmla.XmlaOlap4jDatabaseMetaData.getMetadata(XmlaOlap4jDatabaseMetaData.java:140)
    at org.olap4j.driver.xmla.XmlaOlap4jDatabaseMetaData.getMetadata(XmlaOlap4jDatabaseMetaData.java:70)
    at org.olap4j.driver.xmla.XmlaOlap4jDatabaseMetaData.getDatabaseProperties(XmlaOlap4jDatabaseMetaData.java:1047)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.makeConnectionPropertyList(XmlaOlap4jConnection.java:327)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.generateRequest(XmlaOlap4jConnection.java:1040)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.populateList(XmlaOlap4jConnection.java:852)
    at org.olap4j.driver.xmla.DeferredNamedListImpl.populateList(DeferredNamedListImpl.java:129)
    at org.olap4j.driver.xmla.DeferredNamedListImpl.getList(DeferredNamedListImpl.java:89)
    at org.olap4j.driver.xmla.DeferredNamedListImpl.size(DeferredNamedListImpl.java:109)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.getOlapDatabase(XmlaOlap4jConnection.java:454)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.getOlapCatalogs(XmlaOlap4jConnection.java:530)
    at org.olap4j.driver.xmla.XmlaOlap4jConnection.setCatalog(XmlaOlap4jConnection.java:486)
    at mondriantest.MondrianTest.main(MondrianTest.java:30)
    Caused by: org.xml.sax.SAXParseException; lineNumber: 29; columnNumber: 3; The element type "meta" must be terminated by the matching end-tag "</meta>".
    at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
    at org.olap4j.driver.xmla.XmlaOlap4jUtil.parse(XmlaOlap4jUtil.java:83)
    ... 14 more

    I am using java 1.7.

    anyone can help? thanks

  2. #2
    Join Date
    Mar 2017
    Posts
    2

    Default

    Try this:
    String connectString2="jdbc:xmla:Server=http://localhost:8080/pentaho/Xmla;Catalog=FoodMart;

    Connection cnx = DriverManager.getConnection(connectString2, "Admin", "password");

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.