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

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
knightwriter
Creator III
Creator III

InYear and <Today()

Hi All,

I want to count the number of overdues and my expression is as follows:

=Count(Distinct If([Car_Sales.Status]='Open' AND InYear([Car_Sales.Anticipated Close Date],today(),0 AND [Car_Sales.Anticipated Close Date] < Today(),[Sales Id],)))

I realize the double AND is making the error but Im unsure how to show:

  • Car Sales that have an 'Open' status
  • and In 2015
  • and are less than today

Thanks in advance.

Labels (1)
1 Solution

Accepted Solutions
jvitantonio
Specialist III
Specialist III

Hi,

Please try this:

Count(Distinct

If([Car_Sales.Status]='Open' AND InYear([Car_Sales.Anticipated Close Date],today(),0) AND [Car_Sales.Anticipated Close Date] < Today(),[Sales Id]))

Thanks,

Juan

View solution in original post

3 Replies
jvitantonio
Specialist III
Specialist III

Hi,

Please try this:

Count(Distinct

If([Car_Sales.Status]='Open' AND InYear([Car_Sales.Anticipated Close Date],today(),0) AND [Car_Sales.Anticipated Close Date] < Today(),[Sales Id]))

Thanks,

Juan

sunny_talwar

May be this:

Count(DISTINCT {<Year = {"$(=Year(Today()))"}, [Car_Sales.Status] = {'Open'}, [Car_Sales.Anticipated Close Date] = {"$(='<=' & Date(Today(), 'YourDateFormat'))"}>} [Sales Id])

Anonymous
Not applicable

hi,

May be try:

=Count({<[Car_Sales.Status]='Open',[Car_Sales.Anticipated Close Date] = max(year(Date)),[Car_Sales.Anticipated Close Date] = {'<=$(=Date(Today()))'}>()}Distinct [Sales Id])

Regards

Neetha