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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
riceball
Contributor
Contributor

Aggregation (String)

Hi,

I've encountered some aggregation issue for my expression line in pivot table. Would appreciate some help from you guys

I would like my result to look like this (please see highlighted cells).This column will reflect my product name based on the category='Main' group by Country and Brand

Desired Output.jpg

Thank you very much!

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try:  if(Category='Main',Product, aggr(NODISTINCT concat({<Category={'Main'}>}DISTINCT Product, ' & '),Country,Brand))

See attached example.


talk is cheap, supply exceeds demand

View solution in original post

3 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try:  if(Category='Main',Product, aggr(NODISTINCT concat({<Category={'Main'}>}DISTINCT Product, ' & '),Country,Brand))

See attached example.


talk is cheap, supply exceeds demand
riceball
Contributor
Contributor
Author

It works wonders! Thank you so much for your help!!!

riceball
Contributor
Contributor
Author

Hi,

I wonder if there is any way I can load the expression into the script? I would like to have a listbox whereby my user can select the product name and the desired result (e.g: If Product A1 was selected, the listbox will show A4&A9 as possible selection)

I tried using resident load group by function but it doesn't seem to work.

Thanks!