1

Newbie here. Would appreciate all your help.

I'm trying to write a formula for the following Scenario: Field Name - "Course Interest" has Certificate I, Certificate II, Certificate III, Certificate IV and Diploma in relevant cohorts e.g. Certificate IV in Engineering. I have to create a formula field (Course Level) that will output value as below: Certificate I - Level 1 Certificate II - Level 2 Certificate III - Level 3 Certificate IV- Level 4 Diploma - Level 5

I have the code as below but for Certificate I, II, III and IV it gives the same values for all.

IF
(LEFT(Course_Interest_c,13) = "Certificate I", 
    "Level 1", 

 IF(
        LEFT(Course_Interest_c,14) = "Certificate II", 
        "Level 2", 
     

  IF(
           LEFT(Course_Interest_c,15) = "Certificate III", 
            "Level 3", 

      IF(
                LEFT(Course_Interest_c,13) = "Certificate IV", 
                "Level 4",
             IF(
                    LEFT(Course_Interest_c,7) = "Diploma", 
                    "Level 5",
                    "Not Relevant"
                )
            )
        )))
2
  • field Course_Interest_c is text field?
    – Raj
    Commented Jan 23 at 5:20
  • And can you tried Case? Ref: help.salesforce.com/s/…
    – Raj
    Commented Jan 23 at 5:24

1 Answer 1

1

The issue you're hitting here is that with the order in which you're evaluating the values, the first check for 'Certificate I' is always going to be true for the other values.

To fix this, you could simply evaluate these in the opposite order, i.e. check from Diploma down to Certificate I.

1
  • Awesome! Thank you so much. This worked
    – Shanaya
    Commented Jan 23 at 22:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .