Search code examples
google-visualizationreportingmdxiccube

How should be my MDX query to use Google geo map in icCube ic3report?


According to this, I should select the first column as the city name and the second/third as optional values to be displayed:

https://google-developers.appspot.com/chart/interactive/docs/gallery/geomap?hl=en

However, when I use the following MDX query ic3report does not show me any info on the map, and I already checked the query and it is returning all results:

WITH MEMBER [Measures].[City Name] AS [Customers].[Location].currentmember.name
SELECT
NON EMPTY { {
[City Name],
[Measures].[My Value]
} } ON COLUMNS,
NON EMPTY { NonEmpty( [Customers].[Location].[City].allmembers, [Measures].[My Value]) } ON ROWS
 FROM [My Cube]

Since I could not find any icCube examples on this, can anybody help me?


Solution

  • I'm assuming you'd like to have some "markers" for the cities.

    For that, you can configure the Geo widget Properties:

    Region       : world    (for example)
    Display Mode : markers-name
    

    Then your MDX might be as following using the icCube's demo. Sales cube; the [Measures] being on the axis 0 and the cities on the axis 1 :

    SELECT
    { {[Measures].[Amount]} } ON COLUMNS,
    { [Customers].[Geography].[City].allmembers } ON ROWS
     FROM [Sales]
    

    Note depending on the numbers of markers it might take some time to display them (you could use lat/long instead of names for faster rendering).

    Hope that helps.