Assuming textual representation in a string :
xxx.xxx.xxx.xxx
格式,12+3)这是字符串的最大长度.
Alternatives to storing as string:
INT UNSIGNED
以及INET_ATON
和INET_NTOA
来处理从地址到数字以及从数字到地址的转换SELECT INET_ATON('209.207.224.40'); -> 3520061480 SELECT INET_NTOA(3520061480); -> '209.207.224.40'
BIGINT
(8字节),但是这将使用两个字段.