Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm trying to combine a pre-defined Outer Set Analysis with a pre-defined expression.
I have variables in the script:
MasterItem1
{<Year={'$(vMaxYear)'},Month={'$(vMaxMonth)'},Day={'<=$(vMaxDay)'},Date=,YearMonth=>}
MasterItem2
Sum(distinct {<EVENT_TYPE = {Sales}>} Sales)
This is what I want to use as an expression but it doesn't work:
[MasterItem1]
[MasterItem2]
But this does work:
{<Year={'$(vMaxYear)'},Month={'$(vMaxMonth)'},Day={'<=$(vMaxDay)'},Date=,YearMonth=>}
Sum(distinct {<EVENT_TYPE = {Sales}>} Sales)
Any idea why?
Interesting approach! Combining outer set analysis with another expression defined as a Master Item can lead to deeper insights and herb grinder enhanced data analysis. Excited to see the results of this innovative method in action. Keep up the great work.
I managed to solve it.
Just use dollar sign expansion on the first MasterItem:
$([MasterItem1])
[MasterItem2]
Was to quick to think I had a working solution.
That didn't play so I'm still open for suggestions/help
I'm not sure if you can treat master items as variables. Consider storing your SET modifiers as variables and not master items.
Then you could do this.
=$(var_this_week_2_date) [Masteritem2]
Too bad,
would be great to set up a few vMasterItems for reusability .
The variable overview and editing is not very well implemented.
But thanks for the reply. I'll set the variables in the script and then use them in the Master Items.
Weird though, this almost worked (dollar sign expansion on the variable Master Item), I got results but didn't work when I wanted to check previous month :
$([MasterItem1])
[MasterItem2]
$(vMaxMonth)-1
It is a bit hard to advice when there are multiple layers of variables in play.
What does $(vMaxMonth) return? What does $(vMaxMonth)-1 return? Could it be that your set are expecting a string value 'Jan', 'Feb', etc... and your $(vMaxMonth)-1 returns a integer like 1,2,...?
How do you handle when vMaxMonth is January?
I suggest to re-think the entire approach because combining and/or nesting multiple expression-parts per master-items and/or variables could become the complete opposite to the aim of simplifying the handling. IMO it's only sensible for a few really redundant and/or rather quite complex expressions but not as a general approach.
Interesting approach! Combining outer set analysis with another expression defined as a Master Item can lead to deeper insights and herb grinder enhanced data analysis. Excited to see the results of this innovative method in action. Keep up the great work.