Skip to main content

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Welcome to Qlik Community! Check out our new navigation! FIND OUT MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
sunil-kumar5
Creator
Creator

Aged bucket Days Range along with Future pending task

Hi Community,

 

Suppose there is date column which has previous date, future date and blanks per below.
 
Conditions:
a. If Due date is blank, today or future dated then it shows "active".
b. Previous days ranges from current date like "0-30","31-60","61-90","91-120","121-150"
 
I tried to find out on google in qlik communities and got something but not able to meet my a. condition but met with second condition.
 
Example: 

If(Today()-DueDate <= 30, '0-30 Days',

If(Today()-DueDate <= 60, '31-60 Days',

If(Today()-DueDate <= 90, '61-90 Days',

If(Today()-DueDate <= 120, '91-120 Days',

If(Today()-DueDate <= 150,'121-150 Days', 'Over 150'))))) 
 
Due Date
22-02-2018
10-05-2017
 
26-10-2016
05-08-2020
 
05-04-2019
12-11-2022
 
12-03-2021
 
20-05-2020
09-04-2020
 
10-01-2020
07-09-2020

 

Can someone please help on this as its really much needed?

Thanks

2 Solutions

Accepted Solutions
Kushal_Chawda

try below

if(DueDate>= today() or len(trim(DueDate))=0,'Active',

If(Today()-DueDate <= 30, '0-30 Days',

If(Today()-DueDate <= 60, '31-60 Days',

If(Today()-DueDate <= 90, '61-90 Days',

If(Today()-DueDate <= 120, '91-120 Days',

If(Today()-DueDate <= 150,'121-150 Days', 'Over 150'))))))

View solution in original post

sunil-kumar5
Creator
Creator
Author

Hi Kush,

Thanks for your help in this, it working now !!

View solution in original post

4 Replies
Kushal_Chawda

try below

if(DueDate>= today() or len(trim(DueDate))=0,'Active',

If(Today()-DueDate <= 30, '0-30 Days',

If(Today()-DueDate <= 60, '31-60 Days',

If(Today()-DueDate <= 90, '61-90 Days',

If(Today()-DueDate <= 120, '91-120 Days',

If(Today()-DueDate <= 150,'121-150 Days', 'Over 150'))))))
Usama
Creator
Creator

Hi,

Can you please attach sample app? 

Thanks

From Nothing - To Something - To Everything
sunil-kumar5
Creator
Creator
Author

Hi Kush,

Thanks for your help in this, it working now !!

Kushal_Chawda

Please mark appropriate answer as correct to close this thread