Yow, no. Wait, yes. You could use a activerecord callback for
before_save to change the IP before writing to the database:
but there is no callback for retrieval. Ahha, but we can just overwrite
the method in the model:
self.ip.gsub /2/, '3'
Would replace 2s with 3s.
But really, why not just store it as a string? Why do you want to store
it as a number? It isn't a number, it's an IP.