Formula for a report - text triggers number

  • 0
  • 1
  • Question
  • Updated 1 month ago
  • Answered
I have a column in a report that I want to put a report formula column next to.  The initial column contains text and I want the formula column to put a numeric value based on the text in the first column.  Here's what I've come up with but it doesn't like something here.  Hope you can help.

If ([WRO] contains "W", .5, null )
If ([WRO] contains "R", 1, null )
Photo of Mark Glevicky

Mark Glevicky

  • 536 Points 500 badge 2x thumb

Posted 1 month ago

  • 0
  • 1
Photo of QuickBasePros_IDS

QuickBasePros_IDS, Champion

  • 3,792 Points 3k badge 2x thumb
This is how you write a Contains() statement for your situation: 

If(Contains([WRO],"W"),5,
If(Contains([WRO],"R"),1,
null))


Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 65,634 Points 50k badge 2x thumb
Or shorter...

If(
Contains([WRO],"W"),5,
Contains([WRO],"R"),1)
Photo of Mark Glevicky

Mark Glevicky

  • 536 Points 500 badge 2x thumb
THANK YOU!  Mark
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 65,634 Points 50k badge 2x thumb
... and Laura.
Photo of Mark Glevicky

Mark Glevicky

  • 536 Points 500 badge 2x thumb
I was signing my name  :)  But thank you Laura as well!