Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I hope I have an easy one for you 🙂 I am hoping I am simply overthinking it...
I am trying to get a sum of the amount of products that have a launch date this quarter. I have been able to flag the products as the dates being in the is quarter using:
InQuarter([Launch Date],Today(),0)
Product Group | Product | Launch Date | This Quarter |
-4 | |||
Fruit | apples | 12/31/2018 | 0 |
Fruit | bananas | 1/15/2019 | 0 |
Vegetables | beet | 4/20/2019 | -1 |
Vegetables | carrot | 4/1/2019 | -1 |
Fruit | oranges | 5/1/2019 | -1 |
Vegetables | turnip | 5/25/2019 | -1 |
But what I really want is to show the number of Products Launching THIS quarter by Product group. I know this is wrong, but something like this:
=SUM(if([Launch Date] = InQuarter,Today(),[Product Group]))
Product Group | This Quarter |
Total | 4 |
Fruit | 1 |
Vegetables | 3 |
Thanks in advance!
If you don't have a flag, than may be this
Count({<[Launch Date] = {"=InQuarter([Launch Date],Today(),0)"}>}[Launch Date])
use a straight table with Dimension "Product Group" and Expression:
aggr(sum(if (InQuarter([Launch Date],Today(),0)=-1,1)),[Product Group])
and Show total and you get your desired output
If you have this flag within the data you could use something like:
count({< [This Quarter] = {-1}>} Product)
- Marcus
If you don't have a flag, than may be this
Count({<[Launch Date] = {"=InQuarter([Launch Date],Today(),0)"}>}[Launch Date])
use a straight table with Dimension "Product Group" and Expression:
aggr(sum(if (InQuarter([Launch Date],Today(),0)=-1,1)),[Product Group])
and Show total and you get your desired output
Thanks Marcus,
I get an error - "Error in set modifier ad hoc element list".
Attached is a screenshot.
'This Quarter' is using: InQuarter([Launch Date],Today(),0)
Is there something wrong with the 'This Quarter' expression that is creating the error?
Thank you Sunny!
Indeed that works perfectly! I had tried SO many iterations of the syntax and I was completely missing the "" in the brackets.
Cheers and Happy Friday!
Thank you Hrlinder!
Indeed this works too and the syntax isn't as complicated.
Cheers!