Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
I have three straight tables with the same expressions. The tables are different between them because on everyone I used a different parameter in the single expressions (so table1 will have parameter vParameter1, table2 will have vParameter2, table3 will have vParameter3).
Currently I set the parameters into the set analysis manually, but I would like to add another expression in the tables (e.g. let's call it "Parameter") where I set only the relative parameter for that table (vParameter1/vParameter2/vParameter3) and then in the expression below I call only the said column. This would be really helpful to me in order to maintain the code
It works when I call the expression "Parameter" normally, but I'm unable to do it into the set analysis... It there a way to do this?
Hi,
instead of defining the vParameter variable in an additional "Parameter" expression, you could use parameterized variables as your expressions like:
SET vSold = Sum({$<articolParameter={'$1'}>}articolPrice);
or
LET vSold2 = 'Sum({$<articolParameter={'''&Chr(36)&'($1)''}>}articolPrice)';
hope this helps
regards
Marco
please post sample application.
thanks
regards
Marco
Hi Marco,
hope this helps even if it's a basic example. In my real environment table1, table2 and table3 have many more expressions.
Where I would like to arrive is similar to tableX (which currently doesn't work, of course): defining a new expression (labeled "Parameter" in tableX) I would like to be able to call this expression within the set analysis into the same straight table in order to achieve that the code in the three tables is always the same, except for the value of that single expression "Parameter" (so, ideally, I can set variables for the expressions and manage only once the code instead of three times like now).
Hope this is clear (and possible too),
Riccardo
Hi,
instead of defining the vParameter variable in an additional "Parameter" expression, you could use parameterized variables as your expressions like:
SET vSold = Sum({$<articolParameter={'$1'}>}articolPrice);
or
LET vSold2 = 'Sum({$<articolParameter={'''&Chr(36)&'($1)''}>}articolPrice)';
hope this helps
regards
Marco
Nice solution, didn't thought to do it this way but is much better than it is right now... Thank you!
you're welcome.
Glad I could help.
regards
Marco