I am trying to find a formula for column A that will check an IP address in column B and find if if falls into a range (or between) 2 addresses in in two other columns. C and D.
E.G.
<tbody>
</tbody>
Sorry about the formatting..
I can do a lateral check with
=IF(AND((B3>C3),(B3 < D3)),"yes","no")
which only checks 1 address against the range next to it. I need something that will check the 1 ip address against all of the ranges. i.e. rows 2 to 100..
This is checking access list rules against routes to see if i can eliminate redundant rules... but has other uses if i can get it going. To make it extra special i can not use VBA macros to get it done.
I'm thinking some kind of index match to look it up in an array but not sure how to apply it. I don't know if it can even be done. Good luck.
E.G.
Valid? | address | range | |
start | end | ||
yes | 10.1.1.5 | 10.1.1.0 | 10.1.1.31 |
yes | 10.1.3.13 | 10.1.2.16 | 10.1.2.31 |
no | 10.1.2.7 | 10.1.1.128 | 10.1.1.223 |
no | 10.1.1.62 | 10.1.3.0 | 10.1.3.127 |
yes | 10.1.1.9 | 10.1.4.0 | 10.1.4.255 |
no | 10.1.1.50 | … | … |
yes | 10.1.1.200 | … | … |
<tbody>
</tbody>
Sorry about the formatting..
I can do a lateral check with
=IF(AND((B3>C3),(B3 < D3)),"yes","no")
which only checks 1 address against the range next to it. I need something that will check the 1 ip address against all of the ranges. i.e. rows 2 to 100..
This is checking access list rules against routes to see if i can eliminate redundant rules... but has other uses if i can get it going. To make it extra special i can not use VBA macros to get it done.
I'm thinking some kind of index match to look it up in an array but not sure how to apply it. I don't know if it can even be done. Good luck.