I need my IP list sorted. Problem is that i want them sorted after the value in the first part, then second part and so on.
MYTABLE DATA 20.1.2.1 100.1.1.1 20.1
Store the IP addresses as plain 32-bit integers (it's guaranteed they fit) and sort those. For IPv6 convert to a 128-bit integer instead.