Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
mustafaelryah
Creator
Creator

Controlling Dimension Values

Dear All,

     How can I choose only some values (string values) from my dimension (suppose its dimension_type) of chart.

Looking forward.

3 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

Hi

  • Select from a list box to allow the user to control the selection
  • Use a calculated dimension to filter the values (with suppress nulls for the dimension) - like this:

          =Aggr(If(dimension_type <> 'None', dimension_type), dimension_type)

  • Use set analysis in the expression(s) to filter the values (with suppress nulls/suppress zero values for the expressions) like:

          =Sum({<dimension_type -= {'None'}>} ....)

HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
mustafaelryah
Creator
Creator
Author

Hi,

Thanks a lot, I used a calculated dimension  and I typed this expression

=Sum({<Account_Type ={'operational_expenses'}>}Account_Type)

and syntax is correct in the editor , but when I browsed the chart ,

show me (Error in calculation dimension =Sum({<Account_Type ={'operational_expenses'}>}Account_Type)) message

can you help me please!

MarcoWedel

- you want to sum a field, that holds text values  (Sum Account_Type where Account_Type = 'operational_expenses') or are those dual values?

- When using Aggregations in calculated dimensions, you have to do so using the aggr() function like


=Aggr(Sum({<Account_Type ={'operational_expenses'}>} some_numerical_field), field_to_aggregate_over)

hope this helps

regards

Marco