on 02-20-2014 11:40 PM
Is Union with Constant value functionality available in CE script?
Ramana
Hi Ramana,
You can "fake it" by using Calculated columns (CE_CALC) with constant values, but you'll lose a bit on performance and HANA won't prune those branches when filters are set against those columns.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Depending on your use case, I have had to use scalar variables in SQLScript in WHERE clauses between two select statements to achieve similar performance as branch-pruning graphical CalcViews. You'd use an input parameter rather than WHERE clause.
Example:
SELECT ..
FROM ..
WHERE :input_parameter = 'A'
UNION ALL
SELECT ..
FROM ..
WHERE :input_parameter = 'B'
Jody,
Thanks for such a quick reply. I was indeed going for this functionality to prune the branches of the union. Graphical view is an option, but as there are too many branches, it would have been easier to write the CE script.
Input parameter is not a good option for my use case. The beauty of union with constant value in a graphical view is that the filtering can be done by the end user directly on the displayed data (Ex: Analysis office) and get the benefit of branch pruning in the union.
I hope future versions of HANA can provide this functionality in CE script.
Regards,
Ramana
User | Count |
---|---|
91 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.