2 Replies Latest reply on Mar 15, 2017 7:56 AM by Jessie Wang

    Count Null in Dimension Fields

    Jessie Wang

      Hello everyone,

       

      I have couple dimensions with Null values in it, and this screws up the Count I am trying to use.

       

      Example:

         

      UniqueID

      Dimension1

      Dimension2

      1

      Red

       

      2

      Red

      Yellow

      3

      Red

      Yellow

      4

      Red

      Yellow

      5

       

      Yellow

      6

       

      Yellow

      7

      Red

      Yellow

      8

      Red

       

      9

      Red

      Yellow

      10

      Blue

       

      11

      Blue

       

       

      I want to count total UniqueID that satisfy below requirements:

           1. Dimension1 ="Red"

           2. Dimension2 <>"Yellow"

       

      I wrote,

      If Dimension1 ="Red" and Dimension2<>"Yellow"

      Then 1

      else 0

      End

      So my total count should equal to 2, but since Dimension2 has Null value in there, so it wont count them correctly.

       

      Please help if someone worked with Dimension Null values.

       

      Thank you so much for your time!