Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am Dynamically displaying Expressions/ Measures in Charts based on User Selection thru Subfield Feature and an Inline table with one of the column holding the definition of the expression.
The Problem what I am facing here is when I try to use the Set Analysis with Multiple parameters as part of the expression definition, in inline table load script, it is not working, throwing error . But when I use the same definition outside the inline table and in the chart it works fine.
This problem happens only for the Set Analysis with multiple parameters. Set Analysis with single parameters works fine.
The Set Analysis definition which I am using in the Inline table is
Measures:
LOAD * INLINE [
OrderID, Measures,MeasureEquation
1, NPV, Sum( { <PeriodId= {"<=$(=max(PeriodID))>=$(=($(=Max(PeriodID))-2))"}, [Run Date] = > } NPV)
]
in the above, if add the parameter [Run Date] = , it is not accepting, other parameter being accepted.
Please help me to fix this issue
Does it need to be inline? I couldn't get it to work either (due to the comma and dollar signs) but when I put it into an external file I did.
LOAD OrderID,
Measures,
MeasureEquation & Chr(44) & SecondPart as FullEquation
FROM
[Thread284103.csv]
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
Where the csv file is:
OrderID, Measures,MeasureEquation, Second
1, NPV, Sum( { <PeriodId= {"<=$(=max(PeriodID))>=$(=($(=Max(PeriodID))-2))"}, [Run Date] = > } NPV)
Edit: BTW, I didn't bother with the extra "$(" and ")" in the greater than half of your expression...but it should probably be something like: PeriodId= {"<=$(=max(PeriodID))>=$(=Max(PeriodID)-2)"}
May be try this?
= Sum({< PeriodId = {" $(= '>='&Max(PeriodID)-2&'<='Max(PeriodID))"}, [Run Date]= >} NPV)
Thanks John Cavoulas. I have used CSV Option to resolve my issue.
I too tried with using Variable in the Inline statement, but it didn't work either way. Don't know why.
Thanks for pointing out extra "$(" and ")". I have removed those and used corrected expression in the CSV
Please mark the discussion as "answered Correct". I am not getting that option in the Actions
It doesn't appear to me either. It was clearly marked as a question as it shows "Not Answered" in bold red. I'm logged so that's not it either.
Anyway, glad it helped.
The other possible solution will still break though in as much as it has an additional comma in it.
V/r,
John