2

Is it possible to show the reports filtered by a field (say location) for a user in pentaho?

For eg:

UserA manages RegionA
UserB manages RegionB
UserAB manages RegionA and RegionB

When a user log into the system, (s)he should see the report showing the region only that they manage.

A same report format is shown for all users, but the content (or Query filter) differs for each users.

If this is possible, how to implement this?

Thanks for your assistance.

Gopal
  • 1,372
  • 2
  • 16
  • 32

1 Answers1

3

Yes; The proper way to do this is with session startup actions. These xactions allow you to set session variables which you can then access in your report. In this case you could define a location and use that in your query.

http://wiki.pentaho.com/display/ServerDoc2x/Using+System+Actions+to+Control+Data+Access

Alternatively you can access the username via a session variable too, so you could always put the logic in the query. but the nice thing about the session startup actions is that the logic is contained in one place incase it needs to change.

In your case as this is MDX (which i only just noticed from the tag) you'll have to generate a string that looks like a set of locations.

Codek
  • 5,114
  • 3
  • 24
  • 38