How do I write an if formula where the false result is another if formula?

  • 0
  • 1
  • Question
  • Updated 3 years ago
  • Answered

In other words, if the value in the [Selected Vendor] field is a given text, I want it to return the value in the associated field.

If([Selected Vendor]="Vendor #1",[Vendor #1 Price],(If([Selected Vendor]="Vendor #2",[Vendor #2 Price],If([Selected Vendor]="Vendor #3",[Vendor #3 Price],""))

Photo of Matthew

Matthew

  • 0 Points

Posted 3 years ago

  • 0
  • 1
No problem, just keeping listing the tests and the results.

If(
[Selected Vendor]="Vendor #1",[Vendor #1 Price],
[Selected Vendor]="Vendor #2",[Vendor #2 Price],
[Selected Vendor]="Vendor #3",[Vendor #3 Price])
Photo of Matthew

Matthew

  • 0 Points
This is great! Is there a way to also keep the currency formatting? Currently it returns no formatting.
Photo of Matthew

Matthew

  • 0 Points
Sorry, I figured it out. Thank you!!!
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,224 Points 20k badge 2x thumb
If you are testing the same field for different values you can use a Case() function:

Case([Selected Vendor],
 "Vendor #1", [Vendor #1 Price],
  "Vendor #2", [Vendor #2 Price],
  "Vendor #3", [Vendor #3 Price]
)