INET_ATON(expr): Given a network address, returns an integer that represents the numeric value of the address. : INET_ATON « Miscellaneous Functions « MySQL Tutorial






The generated number is always in network byte order.

The number is calculated as 68*256^3 + 207*256^2 + 224*256 + 40.

mysql>
mysql> SELECT INET_ATON('68.207.224.40');
+----------------------------+
| INET_ATON('68.207.224.40') |
+----------------------------+
|                 1154474024 |
+----------------------------+
1 row in set (0.00 sec)

mysql>
mysql>








22.4.INET_ATON
22.4.1.INET_ATON(expr): Given a network address, returns an integer that represents the numeric value of the address.
22.4.2.INET_ATON() also understands short-form IP addresses