Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
usamabinsadiq
Contributor III
Contributor III

Current Week distinct date count

can anyone help me out?

I am using the following statement and I want the count of the current week's dates, but I am getting 0, I don't see any syntax or logical error, please help me to resolve this.

Count({$<[RECON.Date] = {'>=$(=Date(WeekStart(Max([RECON.Date]), 0, 0))),<=$(=Date(WeekEnd(Max([RECON.Date]), 0, 0)))'}>} distinct [RECON.Date])

if my replay helped you then please press like button and do not forget to press the "Accept as Solution" button.
Labels (1)
1 Solution

Accepted Solutions
usamabinsadiq
Contributor III
Contributor III
Author

The 0 was showing due to a single quote changing it to double quote resolved it, also I removed , from between because of , it was treating it as 2 separate data sets and showing more result then expected.

Count({$<[RECON.Date] = {">=$(=Date(WeekStart(Max([RECON.Date]), 0, 0)))<=$(=Date(WeekEnd(Max([RECON.Date]), 0, 0)))"}>} distinct [RECON.Date])

if my replay helped you then please press like button and do not forget to press the "Accept as Solution" button.

View solution in original post

1 Reply
usamabinsadiq
Contributor III
Contributor III
Author

The 0 was showing due to a single quote changing it to double quote resolved it, also I removed , from between because of , it was treating it as 2 separate data sets and showing more result then expected.

Count({$<[RECON.Date] = {">=$(=Date(WeekStart(Max([RECON.Date]), 0, 0)))<=$(=Date(WeekEnd(Max([RECON.Date]), 0, 0)))"}>} distinct [RECON.Date])

if my replay helped you then please press like button and do not forget to press the "Accept as Solution" button.