Skip to Content
Sep 20, 2007 at 12:01 PM

Dynamically Mapping Scores based on Percentages


Hi Gurus,

I have a scenario....

In a BEx report I have some dynamically calculated percentages. The query is based on Product hierarchy. So the percentages changes based on drilldown levels. I have been asked to map this percentages to some predefined scores.

e.g. if %-age between 5% - 10%.. score is 5, if between 11% - 25%.. score is 10 and so on.

Again these scores are different for different reporting heads and are modifiable from time-to-time. So I cannot hardcode in the query.....

Please give some idea on how to populate the scores at runtime based on the resultant %-age. I can derive it in a function module but don't know how call it directly from a query. Is there any way I can call it from a query?

I am in BW 3.16.

TIA ....