Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have data as below...
ID DateEnd
1
2
3 10/31/2016.
Trying to get the count of ID's which has Date > today () and I am using the below expression,
count(if(date([DateEnd] >Today() ),[ID])) but it is not working
THnaks much
How about this:
LOAD ID,
Date(Date#(DateEnd, 'MM/DD/YYYY')) as DateEnd
FROM....
Count({<DateEnd = {"$(='>' & Date(Today()))"}>} ID)
Looks like you misplaced one bracket,
count(if(date([DateEnd]) >Today(),[ID]))
Try
count(if( [DateEnd] >Today() , [ID]))
Tried that...but no luck
Are your dates correctly intepreted by QV?
yeah...when I put in listbox it is in the following format....10/31/2016
How about this:
LOAD ID,
Date(Date#(DateEnd, 'MM/DD/YYYY')) as DateEnd
FROM....
Count({<DateEnd = {"$(='>' & Date(Today()))"}>} ID)
Try like this using set expression
count({<[DateEnd] = {'=$(=>Today())'} >} ID)
Or script level
Load id, dateend where dateend => today();
It worked fine with this: Is your data coming from somewhere or just trying on some test data as mentioned below.
And hope there is no additional characters beside date like [10/31/2016.]
LOAD * INLINE [
ID, DateEnd
1,
2,
3, 10/31/2016
];
Textbox: I used stefan expression = count(if( [DateEnd] >Today() , [ID]))
It displays 1.
Here comes my herroooo