Forum Discussion

Lee_GC's avatar
Lee_GC
Copper Contributor
Mar 08, 2024

Calculated column returns value based on column drop-down selection MS List

Hello

 

Microsoft List:

 

Column named 'SLA' has drop-down selections:

Urgent
Important
Medium
Low

 

I want to return a value in a calculated column based on selection:

Urgent - 1 
Important - 2 
Medium - 5 
Low - 10 

 

(Values are days)

 

This will provide me column value so that i can create another calculated column in the list based on actual due date from the column start date based on the drop-down selection

 

hope this makes sense!

Thank you in advance

2 Replies

  • Lee_GC Use calculated column formula like below for days calculated column: 

     

    =IF([SLA]="Urgent",1,IF([SLA]="Important",2,IF([SLA]="Medium",5,IF([SLA]="Low",10,0))))

    It defaults to 0 in case if SLA value does not meet the provided options/values. You can adjust it as per your requirements.

     

    Note

    1. Sometimes comma( , ) does not work in formula (it is based on language or regional settings on your site). So in that case use semicolon( ; ) instead of comma( , ).
    2. Use correct display name of your SharePoint columns in above formula.
    3. Wrap column names inside [] if your column name has space in it. For example: [My Column Name]

    Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

  • Hi Lee_GC - you're best off creating all the logic with a Power Automate flow. You could create a calculated column so that depending on the urgency, the number of days is returned as a value in a separate column. However, when you want to create your due date, you won't be able to use that calculated column in your due date calculation.

     

    This article should help: Power Automate Switch Case [How to Use] - Enjoy SharePoint

Resources