Forum Discussion

AsishMathew1's avatar
AsishMathew1
Qrew Trainee
3 years ago
Solved

not isNull in an if statement

If(
[Activity Type Code] = "4" and [Analysis Status] = "Complete", 120*[Actual Modeling Hours Required], 
[Analysis Status]="Complete" and not IsNull([Construction ROM / Scope Estimate]), [Construction ROM / Scope Estimate],
[Analysis Status]="Complete" and ([Cost/UoM]*[Capacity Regain])>0, ([Cost/UoM]*[Capacity Regain]), 
[Analysis Status]="Complete" and [Complexity Code]="1", 500, 
[Analysis Status]="Complete" and [Complexity Code]="2", 1000, 2000)

For some reason, the code does not reach the 4th line, i.e. it doesn't display the result ([Cost/UoM]*[Capacity Regain]). Instead it displays 0. But if I comment out the 3rd line which has the "not isNull" function, the code evaluates all the lines correctly.

The 3rd line works but for some reason the code doesn't get past the 3rd line.

Thoughts? Anything else I could try?



------------------------------
Asish Mathew
------------------------------
  • uncheck the box on that field that says to treat blanks as zero or else test for zero.  Probably better to just test for = 0

    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------

4 Replies

  • The IsNull fuction is not designed to work on text fields.  What field type is
    [Construction ROM / Scope Estimate]​


    If you want to test a text field for blank use

    Trim([my text field])  = ""


     



    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------
    • AsishMathew1's avatar
      AsishMathew1
      Qrew Trainee
      [Construction ROM / Scope Estimate]​​

      is a currency field. 



      ------------------------------
      Asish Mathew
      ------------------------------
      • MarkShnier__You's avatar
        MarkShnier__You
        Qrew Champion
        uncheck the box on that field that says to treat blanks as zero or else test for zero.  Probably better to just test for = 0

        ------------------------------
        Mark Shnier (YQC)
        Quick Base Solution Provider
        Your Quick Base Coach
        http://QuickBaseCoach.com
        mark.shnier@gmail.com
        ------------------------------