Heatmap of Apache access returns an error of too many datapoints

I’m trying to use Grafana 9.4.7 and the Geomap plugin to visualize accesses as the logs from Apache contain coordinates. Unfortunately Grafana complains that the query contained too many data points and has truncated it to 11.

11 data points are plotted as expected on the heatmap but no more.

Using the Flux query:

from(bucket: "telegraf/autogen")
  |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
  |> filter(fn: (r) => r["_measurement"] == "apache_geoip")
  |> filter(fn: (r) => r["_field"] == "client_ip" or r["_field"] == "latitude" or r["_field"] == "longitude")
  |> pivot(rowKey: ["_time"], columnKey: ["_field"], valueColumn: "_value")
  |> group(columns: ["client_ip", "latitude", "longitude"])
  |> duplicate(column: "client_ip", as: "count")
  |> count(column: "count")
  |> group()

This gives the following table:

The exported CSV is of the format:

"client_ip","latitude","longitude","count"
<address>,<latitude>,<longitude>,<count>

With the last line repeating.

How to I properly format this table for Geomap?

Thanks, Al

Recreating the panel has solved to problem, I’d previously changed the panel source from JSON to Flux so I wonder if this was the issue.