By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,510 Members | 1,445 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,510 IT Pros & Developers. It's quick & easy.

Setting Auto-incrementing numbers for IP Address

P: 2
I am confused and not even sure this can work. I have a database that needs to assign licenses that we bought for IP addresses. We have purchased 1000 of these and they are in numeric order. How do I set up an autonumber when the first number would be 14.255.2533.26 for example. Is this possible?
Nov 21 '08 #1
Share this Question
Share on Google+
2 Replies


Expert Mod 2.5K+
P: 2,545
Hi. An IP address is not a number - it is a composite of four octets, and the one you show is not valid. For a basic intro on IP addresses see the following How Stuff Works: What is an IP address article.

We frequently get asked about autonumbers, and this is one of the many occasions when I'd say that autonumbers are unsuited to the task you want to perform.

Personally, if I knew the block of 1000 IP addresses concerned I'd store the IP address value in a lookup table and assign these as needed. I'm not at all convinced that you really mean IP addresses, however, as perhaps you are talking about some kind of licence number that you want to allocate?

In any event it is not a task for an autonumber.

-Stewart
Nov 21 '08 #2

P: 2
Thanks. I mistyped it, but did mean to type a true IP address. I will take your suggestion and use a lookup table.
Nov 21 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.