Sorting IP Address
Hi,
Pardon me for my ignorance! Are the 4 parts in an IP address called
'octives'?
In principle, you could use a combination of LEFT, RIGHT, and LEN functions
to isolate the 3rd and 4th octives into separate columns and then sort them
by those two columns.
But, I thought that the following approach could be simpler.
Let us assume that Column A contains the IP numbers. If there are data in
other columns (Column B, .....) as well, insert 4 blank columns after A.
Copy Column A and paste it in Column B. Select Column B -- "Data" -- "Text
to Columns" -- Select "Delimited" -- "Next" -- Select "Other" and enter a
'period' sign in the box -- "Finish".
Now, the 3rd and 4th octives will be in columns D and E. After sorting the
entire page by columns D and E, you can get rid of columns B, C, D, and E.
Please note that all you need is four contiguous blank columns to do the
above, and they can be anywhere in the sheet. However I suggested that you
have them adjacent to Column A just for convenience.
Regards,
B. R. Ramachandran
"ggant" wrote:
How do I sort fields that contain IP numbers in order? ex. Field A -
192.168.1.0.......192.168.1.121.....192.168.1.15.. ..192.168.2.12....192.168.2.20...192.168.3.50
How can I sort these by the 3rd and 4th octives?
|