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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
fahrizal17
Contributor
Contributor

Sum a Month based date selection

Hello

I have a field "Order Date" that contain date field (MM/DD/YYYY), i want to sum "Sales" full 1 month based on selection date in Dimension script (set analysis), for example if user select on June 15, the sum will calculate all date from June, not only from date 1 until 15 (selection). How i must set my set analysis to do that?

1 Reply
bhavyagrb
Partner - Contributor II
Partner - Contributor II

Hello,

Hope this helps you!!

In Backend:

Please create number formatted  datefield (here DATENUM field is in number format)

In Frontend expression:

sum({<DATENUM={">=$(=num(monthstart(max(DATENUM))))<=$(=num(max(DATENUM)))"},FiscalMonth=,FiscalYear=,[Order Date]=>}Sales)

I have attached the output.

 

Regards,

Bhavya