Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
MRitter
Employee
Employee

Using a Filter when also using Running Total

I have seen some posts about this.  But so far nothing has worked.

I have a line chart using this measure:

Rangesum( Above(
(Sum({<ControlorMail={'M'},retail_quantity_cnt = {">=1"},transaction_dt = {">=$(=CampaignStartDate)<=$(=CampaignEndDate)"},channel=,Tender=,caciquebuyer=>}TotRetailMargin - TotReturnMargin)
-
(Sum({<ControlorMail={'C'},retail_quantity_cnt = {">=1"},transaction_dt = {">=$(=CampaignStartDate)<=$(=CampaignEndDate)"},channel=,Tender=,caciquebuyer=>}TotRetailMargin - TotReturnMargin)
* $(TotalWeightedControlFactor)))
,0, RowNo()))

I want the user to be able to select a range of transaction dates which is the dimension for this chart and have this and other charts that are also using running totals to then react to that selection and only show the days selected.

I have tried every suggestion I have found so far in this community and nothing has worked.  

Thanks

1 Solution

Accepted Solutions
sunny_talwar

okay so you have set analysis on it? are you looking to further drill down transaction_dt once you make selection in it? May be try this

transaction_dt *= {">=$(=CampaignStartDate)<=$(=CampaignEndDate)"}

Use an asterisk before the equal sign.

View solution in original post

6 Replies
Anil_Babu_Samineni

Perhaps this?

Rangesum( Above(
(Sum({<ControlorMail={'M'},retail_quantity_cnt = {">=1"},transaction_dt = {">=$(=Min({1} CampaignStartDate))<=$(=Max({1} CampaignEndDate))"},channel=,Tender=,caciquebuyer=>}TotRetailMargin - TotReturnMargin)
-
(Sum({<ControlorMail={'C'},retail_quantity_cnt = {">=1"},transaction_dt = {">=$(=Min({1} CampaignStartDate))<=$(=Max({1} CampaignEndDate))"},channel=,Tender=,caciquebuyer=>}TotRetailMargin - TotReturnMargin)
* $(TotalWeightedControlFactor)))
,0, RowNo()))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
MRitter
Employee
Employee
Author

That did not work.  When I select a few of the dimension dates it continues to display them all but does recalculate.

I want it to only show the transactions_dt s that are selected like a normal filter would do.

sunny_talwar

You have a set analysis around transaction_dt

transaction_dt = {">=$(=CampaignStartDate)<=$(=CampaignEndDate)"}

What exactly is this doing? Is CampaignStartDate and CampaignEndDate variables? Do they change based on selection in transaction_dt? 

MRitter
Employee
Employee
Author

I am bringing in all transactions to this app.  So when a user selects a campaign I only want the metrics to calculate based on transactions that fall in the range for the start and end dates of that campaign.

sunny_talwar

okay so you have set analysis on it? are you looking to further drill down transaction_dt once you make selection in it? May be try this

transaction_dt *= {">=$(=CampaignStartDate)<=$(=CampaignEndDate)"}

Use an asterisk before the equal sign.

MRitter
Employee
Employee
Author

How do you know all of this stuff?  That worked perfectly.  Thank You.