Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

maheen_vcreatek
New Contributor

Using Created Master Dimension in Color Expression

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

1 Solution

Accepted Solutions
MVP
MVP

Re: Using Created Master Dimension in Color Expression

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!

2 Replies
MVP
MVP

Re: Using Created Master Dimension in Color Expression

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!

maheen_vcreatek
New Contributor

Re: Using Created Master Dimension in Color Expression

Hi Oleg Troyansky,

Thanks for the help. Using Variables helped to solve the problem. It will be good if we can use Master Dimensions directly for Calculations. Hope Qlik will develop this feature in future versions.

Regards,

Maheen

vCreaTek