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

Set Analysis Date Range In Qlik Sense Desktop

Dear Qlik sense experts
I wanna count the number of contract on the next day and from day 2 to day 7,day 8 to day 30 and etc with the date start is today (4/6/2019).  Can someone help me with this? I sincerely appreciate your effort and kind assistance.

Contract NoDate
1071922706/12/2017
1066491602/12/2018
1027031515/11/2018
995018801/05/2018
998319001/11/2018
1017670008/11/2018
1077799208/12/2018
1032588018/11/2017
1084248716/12/2018
1029356917/11/2018
1043969001/09/2018
1057628101/12/2019
1043562301/06/2017
1036840101/12/2018
1013663004/11/2018
1100474719/06/2018
1094187219/12/2018
1059287813/12/2019
1112712901/01/2019
1040209318/04/2018
1102428201/01/2019
1112579001/04/2019
1041378901/12/2018
1016475201/12/2018
1020046410/05/2018
1066180301/03/2019
1067590305/12/2018
1085140914/02/2018
1020129208/01/2018
1009725201/11/2017
1109919401/01/2020
1042594401/12/2018
1082449912/03/2019
1050957001/07/2018
1083897614/12/2018
989880501/11/2017
1097717817/12/2018
1062177701/12/2018
1010163901/11/2018
1108629601/01/2019
1087448916/12/2017
1000103101/11/2018
1016310807/11/2018
1079208709/12/2018
1029737515/11/2018
1111140401/04/2018
1066693801/12/2018
1092401519/12/2018
995796501/11/2017
1102326920/12/2018
1056426001/06/2019
999378001/05/2019
1097224301/01/2019
978643501/11/2018
1064167201/12/2018
1011740402/11/2018
1083922713/07/2018
1107852501/01/2019
1086489716/12/2018
1058297305/12/2018
1111058501/03/2018
1042188718/11/2018
1046067801/12/2019
1037461917/11/2018
1000693001/11/2018
1037197016/05/2019
1109425501/01/2019
1040703501/12/2018
1000281701/02/2018
1057193601/12/2018
1036836301/12/2019
1043828219/11/2018
1015485110/11/2017
1050406701/12/2018
Labels (1)
1 Solution

Accepted Solutions
BlakeGri2093
Contributor III
Contributor III
Author

@Channa : already found the problem for my data set. The format of date field is 'M/D/YYYY' that why i need to use the function date with format reference. This is my expression: count({<Date={"$(=date(today(),'M/D/YYYY'))<=$(=date(today()+30,'M/D/YYYY'))"}>} contract No). Thank you for your suggestion and have a nice day. 

View solution in original post

5 Replies
Channa
Specialist III
Specialist III


=Count({$<Date={"<=$(=Date(Today(),30))>=$(=date(Today(),0))"}>}ContractNo)

 

this will bring upcoming 30 days contracts

 

 

Channa
BlakeGri2093
Contributor III
Contributor III
Author

@Channa : i try your expression but it doesn't work.

Channa
Specialist III
Specialist III

you source file date format has some problem 

 

find the attach

 

=Count({$<Date={"<=$(date(Date(Today(),30),'DD/MM/YYYY'))>=$(date(Date(Today(),0),'DD/MM/YYYY'))"}>} distinct Contract)

Channa
Channa
Specialist III
Specialist III

i change the source

 

please find the xls...ur source has showing nulls

Channa
BlakeGri2093
Contributor III
Contributor III
Author

@Channa : already found the problem for my data set. The format of date field is 'M/D/YYYY' that why i need to use the function date with format reference. This is my expression: count({<Date={"$(=date(today(),'M/D/YYYY'))<=$(=date(today()+30,'M/D/YYYY'))"}>} contract No). Thank you for your suggestion and have a nice day.