Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Qlik experts ,
I am trying to create a chart to show the first appearance of a product in the market.
I used the expression =aggr({<[Year]=>}Min([Year]),[product]) in my Dimension to show all the products and their min year and the data on the bar chart appears correctly.
Now I would want to exclude the year '2015' from the Dimension and show only the products that appeared for the first time between 2016 to 2020, when I try to use the expression aggr({<[Year]=>}min({$<[Year]={'<>2015'}>} [Year]),[Product])
the values for 2015 and 2016 are adding up in the bar chart. Could anybody please help me with the issue.
Ok, I added a clause to ignore selections when calcualtes the min year of each product:
Count({<Year-={2015}>}Aggr(if(Min({1} TOTAL <product> Year)=Year, product), product, Year))
Hi, ycan you try this?: =aggr({<[Year]-={2015}>}Min([Year]),[product])
Or use a simple Year and product as dimensions and set the logic in expression:
Count({<Year-={2015}>}Aggr(if(Min(TOTAL <product> Year)=Year, product), product, Year))
Hello @rubenmarin ,
Thank you. Count({<Year-={2015}>}Aggr(if(Min(TOTAL <product> Year)=Year, product), product, Year)) works however when I select the Year filter , the values adds up again.
Ok, I added a clause to ignore selections when calcualtes the min year of each product:
Count({<Year-={2015}>}Aggr(if(Min({1} TOTAL <product> Year)=Year, product), product, Year))
Thank you @rubenmarin , it works.