Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have a set analysis,in which i have defined
count({<NO={'Ba'},STATUS={'CLOSED'},Year={$(=max(Year))},[ MONTH]={$(=max([ MONTH]))},
[work_DATE] = {"$(=Date(Max([workDATE])-1, 'DD/MM/YYYY'))"},Month_Year=,Quarter=>}SEQ_NO)
now i want to calculate max date of [work_DATE] -1 ( that will give me yesterdays date and there is one conditiion in that max([work_DATE]) where NO=Ba,
how should i give this condition in set or any other method.
Please advise
Didn't get what you meant by "i want to calculate max date of [work_DATE] -1"
means iwa nt to calculate date that is one less then maximum of work date
Your expression is almost correct, you just son't need double quotes:
count({<NO={'Ba'},STATUS={'CLOSED'},Year={$(=max(Year))},[ MONTH]={$(=max([ MONTH]))},
[work_DATE] = {$(=Date(Max([workDATE])-1, 'DD/MM/YYYY'))},Month_Year=,Quarter=>}SEQ_NO)
This expression, however, assumes that the work_DATE is formatted as 'DD/MM/YYYY and that the field MONTH is formatted as a number (not a dual Month). Having said that, what's the point in selecting specific Year and Month if you are selecting Date as the yesterday's date?
Another caveat is the impact of the current selections. Max(Date) returns the max available date, In order to select the maximum possible date in the whole app, you should use
max({1} Date)
cheers,
Oleg Troyansky
Learn advanced Qlik techniques in my book QlikView Your Business
HI ,
Thsi si not working , i do not want mamum date , i want maximum date where NO={'Ba'} this will tell me for this dashboard which is Ba , maximum date for this is . wahta i want.
yes you are right i can remove maximum year and month.
what should be my final expression.
yogita mehta wrote:
.. i want maximum date where NO={'Ba'} this will tell me for this dashboard which is Ba , maximum date for this is .
For that you may try like:
[work_DATE] = {$(=Date(Max( {< NO={'Ba'}>} [workDATE])-1, 'DD/MM/YYYY'))
SO my final expression should be
count({<NO={'Ba'},STATUS={'OPEN'},
[work_DATE] = {$(=Date(Max( {< NO={'Ba'}>} [workDATE])-1, 'DD/MM/YYYY'))SEQ_NO)
but this is not giving me any record