Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, this is my first week with QS and I am struggling with displaying chart for previous month.
My CSV file have start and closed dates like below. The CSV file have last 12 month data If I load only 1 month data then my bar chart looks fine, but my requirement is load 12 month data but show only previous month data in bar chart because my other chart need to have 12 month data.
start date, closed date
2/24/2020 02:00, 2/25/2020 17:00
=MonthName(addmonths(today(),-1)) , this gives me Mar 2020 which is correct
=Max(date([Start Date.autoCalendar.YearMonth])) , this gives me 3/1/2020 which is also correct but how can I club both to get only March 2020 records in chart? any help will be appreciated .
the chart start date and closed date both should fall in Previous month, which is March 2020 in this example
Hi,
What you require is Set analysis. Your expression should be like this.
Sum({<[Start Date] = {">=$(=Monthstart(Addmonths(today(),-1)))<=$(=Monthend(Addmonths(today(),-1)))"},
[End Date] = {">=$(=Monthstart(Addmonths(today(),-1)))<=$(=Monthend(Addmonths(today(),-1)))"}>}Sales)
Hi, I think its working ok now, thanks a ton but now I have to put this code in all other charts
is there a way I can put that code in variable and then in chart I will count only if the variable output is True?
Also can you also help me how can I add multiple AND in this? I need to add a wild match in above analysis to see a certain field is = to something
count(if(WildMatch(Status ,'*Closed*'), Status))