Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
=sum({<[Invoice Period]={" $(=date(MAX([Invoice Period]),'YYYY-MM'))"}>}[Actual Total]) is working but
=sum({<[Invoice Period]={"<= $(=date(MAX([Invoice Period]),'YYYY-MM'))"}>}[Actual Total]) is showing zero
object : textbox
tool :qlikview 12.x
regards
Pradosh
In fact, I thought same earlier, I thought to ask stalwar1 or hic fortunately i missed that. Someway, I got to know the issue
=sum({<[Invoice Period]={"<=$(=date(MAX([Invoice Period]),'YYYY-MM'))"}>}[Actual Total]) is showing zero
Here, What i understand is Set analysis with some spaces won't allow. If you remove i believe this should work. Not really sure what is the cause..
try this
what is the date format ?
=sum({<[Invoice Period]={'<= $(=date(MAX([Invoice Period]),'YYYY-MM'))'}>} Dsiticnt [Actual Total])
This could be because your YYYY-MM formatted [Invoice Period] is possibly a text field. Text field comparison could work with '=' but not really with '<='. Ideally, you should create a dual date field in the script.
In fact, I thought same earlier, I thought to ask stalwar1 or hic fortunately i missed that. Someway, I got to know the issue
=sum({<[Invoice Period]={"<=$(=date(MAX([Invoice Period]),'YYYY-MM'))"}>}[Actual Total]) is showing zero
Here, What i understand is Set analysis with some spaces won't allow. If you remove i believe this should work. Not really sure what is the cause..
Thank you for your suggestion.
It's a date and it is working fine now after i followed Anil's suggestion and removed the space.
strange!!
regards
Pradosh
Strange !! thats the case here. I have never encountered this bug(if it is a bug) before. its working fine now Anil. let me experiment a little and i will close the thread.
regards
Pradosh
Yes, Anil is right, for some reason spaces after <=, <, >, >= and before $() cause the expression to now work.... so don't have them
Any reason, What it could be and If we use in script looks like we've got as expected like
If(Field <= 10, 1,0)
So, let me clarify... the issue is related to spaces in set analysis... for example
Sum({<Number = {"> 10 < 15"}>} Sales)
vs
Sum({<Number = {">10<15"}>} Sales)
I have not done any testing, but I think first expression won't work because of spaces, while the second one will... when I say it won't work, I mean it will just ignore set analysis on Number field....