Search code examples
jsonrestmdxjasperserver

How to get the result of an MDX query as a JSON object in JasperReports Server


Is it possible to create something like an "MDX query object" on JasperReports Server and then retrieve the data set as a JSON object through a REST call?

If so, is it possible to parameterize the query and set the parameter through the REST call?

BACKGROUND

I have just started using Jaspersoft. Before that, I briefly used Pentaho BI server, where it is possible to define Datasource components associated to specific (parameterized) MDX queries. My objective is to do something similar on JasperReports Server, but I need to retrieve the data as a JSON in order to use a custom Javascript library to build the dashboard view.

WHAT I HAVE TRIED

I have built an OLAP view using a (non-parameterized) MDX query, but I could not find a REST call which returns the data set.

RESTRICTIONS

I am using JasperReports Server 6.3.0 COMMUNITY EDITION.


Solution

  • You can't get the result of an MDX query as a JSON. In the newest Jasperserver relise you can get result of AdHoc Crosstab or Table view as a JSON. You also can create JSON query and execute it on Domain or Adhoc View. But unfortunately you can't run MDX and have JSON result. And as I know Jasperserver wan't to drop support MDX. So be careful to using it.