0

Optimize Formula

switch Medicion do
case 1:
    (select DOCUMENTOS where 'Ganado REAL' = 10)
case 2:
    (select DOCUMENTOS where 'Ganado REAL' = 50)
case 3:
    (select DOCUMENTOS where 'Ganado REAL' = 80)
case 4:
    (select DOCUMENTOS where 'Ganado REAL' = 90)
case 5:
    (select DOCUMENTOS where 'Ganado REAL' = 100)
case 6:
    (select DOCUMENTOS where 'Ganado REAL' = null)
case 7:
    (select DOCUMENTOS where 'Ganado REAL' < 'Ganado PLAN')
end

I like to optimize this formula, and the last case 7 don't work.

2replies Oldest first
  • Oldest first
  • Newest first
  • Active threads
  • Popular
  • The reason why case 7 doesn't work is the fact you don't have a option 7 in your choice field, change it to 'default:'  instead, this means if there are no selections ,so your choice field is empty, then the defauld value would be picked. The formula looks good and no need for optimization needed in my eyes since you only use the select function only once in any case.

    Steven

    Like
      • Rafael
      • Rafael Sanchis
      • Rafael_Sanchis
      • 2 mths ago
      • Reported - view

      RoSoft_Steven 😵 Thanks Steven 

      Like
Like Follow
  • Status Answered
  • 2 mths agoLast active
  • 2Replies
  • 22Views
  • 2 Following