Hi there, I'm stuck at something in Excel so after some failed Google searches I've decided to appeal to solidarity here.

For example, if I assign number "1" to Room 8005 and I have another listing associating many objects with that room using the number 8005, I need to give those objects the number "1" too.
Imagine this procedure for hundreds of rooms and thousands of objects.

I know this process can be automated in Excel but I can't work it out.

I'm attaching a Excel file excel.xlsx that ilustrates what I intend to do, if anyone wants to lend me a hand, THANKS in advance.