I have a file at work that has two sheets; "Subnet Info" & "Machine Info".
The Subnet Info sheet has the subnet details, like the subnet network address in one column (let's say A e.g. A2 = 10.10.0.0) & the mask in the other column (let's say B e.g. B = 16 where 16 means /16). Please see the image below.
Clipboard Picture (2022.03.02 11.32.22).png
The Machine Info sheet has the IP address of the servers in the environment along with some other information. What I want to achieve is that in the column (let's say D, marked in red in the picture), we look up the machine IP address and understand which IP range it falls under based on the subnet from the Subnet Info sheet and return that in Column D.
Clipboard Picture (2022.03.02 11.34.04).png
I know this is a forum to get help and not a job request, but I don't know where to start. Can this be done with Formula or VBA macro better? If yes can someone point me in the right direction? If someone has written something similar and can share that, it will be highly appreciated.
Please find the sample file attached.
P.S: I have data in the range of 200+ subnets and 2000+ in the machine info sheet.
Bookmarks