INET_ATON() also understands short-form IP addresses : INET_ATON « Miscellaneous Functions « MySQL Tutorial






mysql>
mysql> SELECT INET_ATON('127.0.0.1'), INET_ATON('127.1');
+------------------------+--------------------+
| INET_ATON('127.0.0.1') | INET_ATON('127.1') |
+------------------------+--------------------+
|             2130706433 |         2130706433 |
+------------------------+--------------------+
1 row in set (0.00 sec)

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