This tutorial describes how to convert an IP address to a long value and back using code in C# and T-SQL. You will learn why it is more efficient to analyze and store an IP address as an 8 byte integer. After you finish the tutorial, you will be up to speed in converting IP addresses to long values and back both in the ASP.NET front end and SQL Server database backend.
