Quantcast
Channel: Pentaho Community Forums - BI Platform
Viewing all articles
Browse latest Browse all 2893

Using the username for rights within a report

$
0
0
Hello all,

At this moment i am pretty familiar with Pentaho. But now i want to know if something is possible.
I want to use the username which the employees login with as a variable in the parameter selection of a report.
I have a report created which about 60 of my employees use. But not everyone is allowed to see everything in this report.
So here is what i want to do:

Lets say i am a car dealer which has different brands of car for sale.
I have for instance 5 users which are allowed to use the report: Alpha, Bravo, Charlie, Delta, Echo.
Alpha is responsible for Ford,
Brave is responsible for Volkswagen,
Charlie is responsible for BMW,
Delta is responsible for Chevrolet,
Echo is allowed to see all the above.

Is it in my report possible to use the following query for the parameter:
Code:

SELECT case when ${Username} = 'Alpha' then 'Ford'
              else  case when ${Username} = 'Bravo'  then 'Volkswagen'
              else  case when ${Username} = 'Charlie' then 'BMW'
              else  case when ${Username} = 'Delta' then 'Chevrolet'
              else  case when ${Username} = 'Echo' then 'All'
              else  NULL end end end end end

But i dont know how to accomplish it to use the variable Username.

Can anyone help me? Otherwise i have to publish 60 different reports all with a other parameter query

Thanks in advance!

Viewing all articles
Browse latest Browse all 2893

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>