Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I need to create a chart in Qlik view which will show the YTD Count of Transaction ID and Sum of Amount.
Date Field is - [Formula - Txn Month]
I have attached the sample excel and .qvw file
I wrote the YTD set expression in the Chart but not working
Regards,
Siba
Hi,
First of all it's common practice to get YTD flags inside the master calendar, in your app there are only three columns, so i'm not sure if you're aware of it.
As for the formula itself, first you got Year & Month fields in the set analysis which are not within the model.
Second of all, the criteria is for YTD last year (-1), so there is no data that match it within the sample data.
Third, Qlik is case sensitive, you wrote Amount where the field name is actually AMOUNT.
Last, you need to make some changes to the set anlaysis part, see the right one below
=sum({$< [Formula - Txn Month]={">=$(=(YearStart(Today(),0)))<=$(=AddYears(Today(), 0))"}>}AMOUNT)
Regards,
Eliran.
If the response you received allowed you to get things working, we would appreciate it if you would close out the thread by using the Accept as Solution button on that post to mark things. This gives the poster credit for the assistance and lets the other Community Members know that was the information you needed. If you did something else to resolve things, you can post what you did and then use the button on that post.
Here are a couple of other Design Blog posts that may be helpful too:
https://community.qlik.com/t5/Qlik-Design-Blog/A-Primer-on-Set-Analysis/ba-p/1468344
https://community.qlik.com/t5/Qlik-Design-Blog/Set-Analysis-in-the-Aggr-function/ba-p/1463822
Regards,
Brett