Forum Discussion

RoulaHabbal's avatar
RoulaHabbal
Qrew Cadet
22 days ago

Formula-Numeric Field Returning Null Instead of 0

Hello:

My current formula-numeric field returns null, instead of 0.

How could I tweak the formula below to return 0? 

Please note:

A. The numeric fields below have the "treat blank values as ''0' in calculations" enabled:

  1. GPA - Associate Degree
  2. GPA - Bachelor's Degree

B. The Primary Program Name and Secondary Program Name are text fields.

*********************************************************

var number AssociatesDegreeScore = If([GPA - Associate Degree]>=3.3, 2);
var number BachelorsDegreeScore = If([GPA - Bachelor's Degree]>=3.3, 3);

var number FinalScore = If(
    not IsNull([GPA - Bachelor's Degree]), $BachelorsDegreeScore,
    not IsNull([GPA - Associate Degree]), $AssociatesDegreeScore,
    0
);

If([Primary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)" or [Secondary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)", $FinalScore)*1.5

*********************************************************

Thank you,

Roula

  • Try this

    var number AssociatesDegreeScore = If([GPA - Associate Degree]>=3.3, 2,0);
    var number BachelorsDegreeScore = If([GPA - Bachelor's Degree]>=3.3, 3,0);

    var number FinalScore = If(
       [GPA - Bachelor's Degree]>0, $BachelorsDegreeScore,
       [GPA - Associate Degree]>0  , $AssociatesDegreeScore,
        0
    );

    If([Primary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)" or [Secondary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)", $FinalScore)*1.5

     

     

  • Try this

    var number AssociatesDegreeScore = If([GPA - Associate Degree]>=3.3, 2,0);
    var number BachelorsDegreeScore = If([GPA - Bachelor's Degree]>=3.3, 3,0);

    var number FinalScore = If(
       [GPA - Bachelor's Degree]>0, $BachelorsDegreeScore,
       [GPA - Associate Degree]>0  , $AssociatesDegreeScore,
        0
    );

    If([Primary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)" or [Secondary Program Name]="Nursing, Associate Degree - LPN to ADN Option (A45110L)", $FinalScore)*1.5

     

     

    • RoulaHabbal's avatar
      RoulaHabbal
      Qrew Cadet

      Good morning, Mark.

      That did it.

      Thank you very much for your help. I appreciate it.

      Roula