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

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Kaushik2020
Creator III
Creator III

Data for May showing as Q1

i have selected below options as part of Filters. 

kaushi2020_0-1698914297101.png

I am using below in load editor to calculate Quarter.

'Q' & ceil(month(act_date)/3) as "Quarter"

Please see below line chart, it shows the point as Q1 which is misleading.

kaushi2020_1-1698914381241.png

my expression to calculate the count.

 

if(count(distinct{<[Activation Year]=, [Activation Month]=, [Activation Quarter]=, current_fraud_bad_debt_category={'Fraud'},
act_date={">=$(=date(yearstart(max(act_date))))<=$(=date(monthstart(addmonths(max(act_date),-3))))"}>} contract_id)
+
Sum({<act_date={">=$(=date(monthstart(addmonths(max(act_date),-3))))<=$(=date(max(act_date)))"}>}projected_fraud_cnt)=0, null(),
count(distinct{<[Activation Year]=, [Activation Month]=, [Activation Quarter]=, current_fraud_bad_debt_category={'Fraud'},rp_type={'POSTPAID VOICE'},
act_date={">=$(=date(yearstart(max(act_date))))<=$(=date(monthstart(addmonths(max(act_date),-3))))"}>} contract_id)
+
Sum({<rp_type={'POSTPAID VOICE'},act_date={">=$(=date(monthstart(addmonths(max(act_date),-3))))<=$(=date(max(act_date)))"}>}projected_fraud_cnt))

 

2 Replies
rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

Your expression to calculate Quarter looks to correct. To debug, make yourself a table chart of act_date, Month(act_date) and Quarter to see if you can determine what's happening. 

-Rob

Kaushik2020
Creator III
Creator III
Author

Thanks for your reply. Seems we are showing data for Selected month -3. My bad that forgot to check. 

So here in this case when selected month is May-which is Q2. we are showing data for Jan which is Q1. 

I think that's the reason QlikSense is showing the Count under Q1.