List:General Discussion« Previous MessageNext Message »
From:Chris Knipe Date:August 26 2006 7:03pm
Subject:IP Address Function?
View as plain text  
Hi,

I need to make *allot* of queries from a application dealing with IP 
Addresses.  At the moment, I'm storing IP addresses as a VARCHAR(16).  I 
would *like* to store them as Integers by converting the IP to it's 
numerical equivalent.  I believe this would also save a enormous amount of 
table space.

The problem is, I *must* do the conversion as part of my SQL Query.  Either 
during the SELECT/UPDATE/INSERT, or via a Procedure... And I must obviously 
also be able to convert the Integer back into a IP address during 
queries....

Is this at all possible???

It's all explained very nicely at 
http://www.aboutmyip.com/AboutMyXApp/IP2Integer.jsp  But how to do this as 
part of a query... *frown*

Any help appreciated...


Regards,
Chris. 

Thread
IP Address Function?Chris Knipe26 Aug
  • Re: IP Address Function?nigel wood26 Aug
  • Re: IP Address Function?Chris Knipe26 Aug