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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Hoowling
Contributor III
Contributor III

Index comparison unaffected by selections

Hi community, 

 

I would like to compare historical stock prices to an index. 
All stocks and indexes are located in the same dimension: Bolagsdata.Bolagsnamn. 
The price data is stored in another dimension: Closeprice. 

In below graph the expression is simply "=Closeprice" , over a period dimension. 
I want to display the index in the graph, which is "OMXS ALL GI" (see below list box), regardless of which stock that is selected. 

Any thoughts on how to achieve this? 

Snipaste_2019-08-15_21-36-01.png

1 Solution

Accepted Solutions
dplr-rn
Partner - Master III
Partner - Master III

try something like below. basically first part shows all possible values of product and second part forces 1 product to be always shown

Sum({
<Product=p(Product)>
+<Product={'All-Purpose Bike Stand'}>}
Sales)

View solution in original post

2 Replies
dplr-rn
Partner - Master III
Partner - Master III

try something like below. basically first part shows all possible values of product and second part forces 1 product to be always shown

Sum({
<Product=p(Product)>
+<Product={'All-Purpose Bike Stand'}>}
Sales)
Hoowling
Contributor III
Contributor III
Author

Thanks! The correct expression to use was the second part of your suggested expression: 

Sum({
<Bolagsdata.Bolagsnamn={'OMXS ALL GI'}>}Closeprice)