Geolocated Accuracy Radius with MaxMind GeoIP2 (mm2accuracyradius)
Description
Geolocates an IPv4 or IPv6 address and returns the accuracy radius, in kilometers, around the latitude and longitude with a 67% confidence, using MaxMind GeoIP2 services. Use this to enrich your query with information about the level of accuracy of calculated geolocation information.
How does it work in the search window?
This operation needs only one argument:
Argument | Data type |
---|---|
Ip (v4 or v6) mandatory | ip, ip6 |
The data type of the new column is float.
Example
In the demo.ecommerce.data
table, we want to get the accuracy radius corresponding to the IP addresses in our clientIpAddress column. To do it, click Create column and select the Geolocated Accuracy Radius with MaxMind GeoIP2 operation. The arguments needed are:
Ip (v4 or v6)Â -clientIpAddress column
The result is a column of float data type containing the calculated accuracy radius in kilometers.
How does it work in LINQ?
Use the operator select
... as
... and add the operation syntax to create the new column. These are the valid formats of the Geolocated Accuracy Radius with MaxMind GeoIP2 operation:
mm2accuracyradius(ip)
mm2accuracyradius(ip6)
Example
Copy the following LINQ script and try the above example on the demo.ecommerce.data
 table.Â
from demo.ecommerce.data
select mm2accuracyradius(clientIpAddress) as accuracyRadius