Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Neo2
Contributor
Contributor

Sum values in within a data range Qlik sense Desktop

Hi
Looking for some expertise on Qlik-sense Desktop. I'm developing a chart where there are three products, three leads showing sales performance for a period a period of days. Refer excel of a simple presentation. Want to replicate the sales amount for a period of days (example 1 Sep to 10 Sep) for each product and sales lead has achieved.
 
 Want to replicate the same formula or something similar in Qlik-sense either as an expression to the value field in front end or if there is a better way for example to be done via load editor; are options.
Labels (2)
2 Replies
sidhiq91
Specialist II
Specialist II

@Neo2  In the  back end first load the data as show below:

NoConcatenate
Temp:
LOAD
Date(Date#("Date Dimension",'YYYYMMDD'),'MM/DD/YYYY') as "Date Dimension",
"Product Dimension 2",
"Person Dimension 3",
"Measure",
Code
FROM [lib://Qlik Community Practice/Example sumifs calculation.xlsx]
(ooxml, embedded labels, header is 2 lines, table is Sheet1)
;

NoConcatenate
Temp1:
Load *
Resident Temp
where "Date Dimension">='09/01/2022' and "Date Dimension"<='09/10/2022';

Drop table Temp;

Exit Script;

In the Front End Create a Pivot Table and and the expression would be sum(Measure) and you will get the expected output.

sidhiq91_0-1666696328611.png

If this resolves your issue, please like and accept it as a solution.

Neo2
Contributor
Contributor
Author

Hi Sidhiq

It's helpful. Say if your boss wants a week vs week comparison in like shown below. I feel it's better to have it in chart form. Then there will be two measure columns. How is the best way to handle this kind of layout and appropriate expression.  

Neo2_1-1666752633446.png

 

Follow up question regarding this expression 

where "Date Dimension">='09/01/2022' and "Date Dimension"<='09/10/2022';

You are using 'Where' and joining the two arguments with 'and' in the middle?

Thanks in advance