Filter project member depending on current user

Hi, I have some questions building reports.

  1. I want to make some dynamic reports depending on logged in user.
    I found the way to select current user dynamically here, Open Dashboard using parameter - #2 by daina.tupule, so I made a member ‘Current Assignee’ as following.
    Aggregate(
    IIF( Count([Assignee].[User].getMemberByKey(CurrentUser()))>0,
    [Assignee].[User].getMemberByKey(CurrentUser()),
    {})
    )

But this time, I’d like to make dynamic member ‘My Project’, the project users work for.

For example,
Project A - Assignee a, Assignee b, Assignee c
Project B - Assignee a, Assignee d, Assignee e
Project C - Assignee f

When user ‘a’ see the report, ‘a’ can see project ‘A’ and ‘B’ below ‘My Project’.
When user ‘f’ see the report, ‘f’ can see project ‘C’ below ‘My Project’.
It seems that there is no direct link between project and assignee. Is it possible to use join or something, in this case?

  1. Is there any good way to get the number of assignees who work for the project?
    I made a measure ‘Assignees’ as following, but there must be a better way to count assignees I think.
    Could you give me some advice?
    – Count assignees who resolved issues or have issues to do
    NonZero(
    Sum(
    Filter(Descendants([Assignee].CurrentHierarchyMember, User)
    ,([Measures].[Issues resolved] + [Measures].[Issues due]) > 0)
    ,1 ))

  2. Using ‘Assignees’ measure I created like #2, it only works when I don’t use ‘Current Assignee’ member I created like #1, because when I select ‘Current Assignee’, there is no other assignee on the report. Can I get the number of assignees regardless of the assignee page? I don’t know how to implement it. I even have no idea whether it is possible or not…

Any advice you give can be a big help for me.
I’m looking for any tips or recommendations. Thank you.

1 Like

In eazyBI dimensions are linked via measures. You would like to use some measures to get the intersection between two dimensions.

You can try creating a calculated member in Project dimension My Projects with this formula:

Aggregate(
  Filter(
    [Project].[Project].Members,
   DefaultContext(
    ([Measures].[Issues created],
     [Assignee].[User].GetMemberByKey(
       CurrentUser()
     ),
     [Project].CurrentMember)
  ) > 0
))

It will give you a list of projects where there is at least one assigned issue.

Please note the calculated member will give you a warning that you are using Assignee and Meausrs within the Project dimension. Those calculated members might work for some scenarios. However, thy might lead to some performance problems or inconsistent behavior in some reports. Use this with caution.

Daina / support@eazybi.com

3 Likes