Table of Contents | ||||||
---|---|---|---|---|---|---|
|
Description
Geolocates an IPv4 address and returns its ASN (autonomous system number). An ASN is a unique number assigned to an AS (autonomous system).
Note |
---|
This operation returns data for public IP addresses only. If an IP is private, it will return null. |
Note |
---|
Use the Geolocated ASN with MaxMind GeoIP2 (mm2asn) operation if you want to get the ASN of an IPv6 address (ip6 data type). |
...
Use the operator select
... as
... and add the operation syntax to create the new column. The syntax is as follows:
mmasn(ip)
Example
Copy the following LINQ script and try the above example on the demo.ecommerce.data
table.
Code Block |
---|
from demo.ecommerce.data select mmasn(clientIpAddress) as asn |