Help

How assign a number to a single selection value

Topic Labels: Formulas
Solved
Jump to Solution
4827 8
cancel
Showing results for 
Search instead for 
Did you mean: 
Jerrel
4 - Data Explorer
4 - Data Explorer

Hello everyone,

I am new to airtable. I have a survey and each question has a single select field option for the answers with a certain amount of points. How can I assign a number to each single select field value e.g. a=0, b=1, c=2 and d=3 so I can add up these points.

Hope to hear from you.

Thanks 

 

1 Solution

Accepted Solutions
Christian_Sabou
5 - Automation Enthusiast
5 - Automation Enthusiast

It's a pleasure! Please mark this post as solved 🙂

See Solution in Thread

8 Replies 8
Christian_Sabou
5 - Automation Enthusiast
5 - Automation Enthusiast

This will require an additional Function field with a switch statement:

 

 

SWITCH({Answer field},"Answer one",1,"Answer two",2,0)

 

 

The last 0 being the default value if nothing is selected

Jerrel
4 - Data Explorer
4 - Data Explorer

Hi Christian,

Thank you for the quick response. I tried it and I get an error prompt (see attached file). Am I missing something?

 

 

Christian_Sabou
5 - Automation Enthusiast
5 - Automation Enthusiast

You are missing the end parenthesis. The hint is the little squiggly line under the front one. Otherwise it should work.

Now with the end parenthesis added it does not seem to work.

 

Christian_Sabou
5 - Automation Enthusiast
5 - Automation Enthusiast

Oh, It's the closing bracket that's extra now. 

SWITCH({Answer field},"Answer one",1,"Answer two",2,0)
Jerrel
4 - Data Explorer
4 - Data Explorer

Yes! It works! Thank you so much Christiaan. 

Regards,

Jerrel

 

Christian_Sabou
5 - Automation Enthusiast
5 - Automation Enthusiast

It's a pleasure! Please mark this post as solved 🙂

Hi, 

Is it possible to add multiple columns to the SWITCH formula to have a sum of single select columns that have the same options and points?