2 Replies Latest reply: Mar 7, 2016 9:31 AM by Maheen Umashankar RSS

    Using Created Master Dimension in Color Expression

    Maheen Umashankar

      Hi All,

       

      I have created Master Item for Dimension. I want to use this Dimension master item in color code by expression. Dimension Master item is not getting recognized in color code expression. Is there any way to do this?

       

      Thanks in Advance.

       

      Regards,

      Maheen

      vCreaTek

        • Re: Using Created Master Dimension in Color Expression
          Oleg Troyansky

          Hi,

           

          I don't think any of the Master Items (Dimensions & Measures) can be referenced in any of the formulas. It would make a nice Idea, i.e. a suggestion for a future development.

           

          For now, you need to use the actual field names or calculations in formulas. If you need to use the same calculation several times, you can store the calculation in a variable and then reference the variable in a $-sign expansion. For example:

           

          vMasterDim = 'IF(A=B, 'Good', 'Bad')

           

          Color Expression:

           

          IF( '$(vMasterDim)' = 'Good', Green(), Red())

           

          This is overly simplified, of course, but it should get the message across.

           

          cheers,

          Oleg Troyansky

          Upgrade your Qlik skills at the Masters Summit for Qlik - coming soon to Milan, Italy and Austin, TX!