Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

How to map out Number IDs to Labels (Identifiers) in Google Sheets

I want to map out number ranges into labels and have a specific cell return the label if it contains the numbers.

Let’s say we have these number ranges.

3550000..3559999 | ProductA

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

3640000..3649999 | ProductB

5250000..5259999 | ProductC

How would I define these ranges of numbers into labels?

Then check if a specific cell contains something like, ‘3642515’ return what product it belongs to? Thanks so much!

>Solution :

if A1 = 3642515

try:

=VLOOKUP(A1, {3550000, ProductA; 
              3640000, ProductB; 
              5250000, ProductC}, 2, 1)
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading