The following query used to work with Grafana 7.X.X and Worldmap-panel 0.3.2.
The country returns a 3 letter country code as shown in the data/countries_3letter.json file. I believe the problem appears to be that the data source no longer returns the result as expected by the plugin with multiple data points.
SELECT
date as time,
country as metric,
count(country) as total
FROM entries
WHERE
date BETWEEN '2021-08-05T10:06:29.165Z' AND '2021-08-12T10:06:29.165Z'
AND profile in (
'https://example.com'
)
GROUP BY date, country, metric
ORDER BY date
When isolating the query to return only one country, in the example below, "Japan" (jpn), it works as expected, with the caveat being it only shows one data point.
SELECT
date as time,
country as metric,
count(country) as total
FROM entries
WHERE
date BETWEEN '2021-08-05T10:06:29.165Z' AND '2021-08-12T10:06:29.165Z'
AND profile in (
'https://example.com'
)
AND country = 'jpn'
GROUP BY date, country, metric
Versions Grafana: 8.0.3 Worldmap-panel: 0.3.3 Datasource: TimescaleDB
Query format: Timeseries
The following query used to work with Grafana 7.X.X and Worldmap-panel 0.3.2.
The
country
returns a 3 letter country code as shown in the data/countries_3letter.json file. I believe the problem appears to be that the data source no longer returns the result as expected by the plugin with multiple data points.When isolating the query to return only one country, in the example below, "Japan" (jpn), it works as expected, with the caveat being it only shows one data point.