title: MDX Show all months for a person if any of the months have a value of "Y" in a separate dimension
body: <p>Have a funky issue i'm trying to resolve if you'd be so kind.  </p>
  
  <p>Measures: BillableHours</p>
  
  <p>Dimensions:</p>
  
  <p>Personnel (EmployeeId, EmployeeName)</p>
  
  <p>Grouping(EmployeePeriodKey, ActiveFlag)</p>
  
  <p>PeriodCalendarYear, CalendarQuarter, CalendarPeriod)</p>
  
  <p>Grouping dimension has flags and calcs that are particular to a person in a period so the PK is the combo of EmployeeId and CalendarPeriod.</p>
  
  <p>Data As Follows:</p>
  
  <p>EmployeeId   CalendarPeriod   ActiveFlag   BillableHours</p>
  
  <p>123              201501              Y                10</p>
  
  <p>123              201502              Y                20</p>
  
  <p>123              201503              N                30</p>
  
  <p>123              201504              Y                40</p>
  
  <p>People are filtering on "Active Flag" = "Y" and missing the "N" row in the results which is not what is desired.  Whatever filter I design needs to be flexible enough that at an employee level I need to know if an employee ever had a value of "Y" JUST the periods selected by the query.</p>
  
  <p>Scenario 1: user selects employee 123 for periods 201501:201504 and filters hypothetical flag to "Y" - Billable Hours should be 100, not 70.</p>
  
  <p>Scenario 2: user selects employee 123 for periods 201501:201503 and filters hypothetical flag to "Y" - Billable Hours should be 60, not 30.</p>
  
  <p>Scenario 3: user selects employee 123 for period 201503 and filters hypothetical flag to "Y" - Billable Hours should be 0, not 30. since in this selected group of periods this person was not active for any period</p>
  
  <p>i'm not interested in all siblings, just the ones at a person level.  And if person is not selected I need it to know to perform this check on a person level for the periods filtered for.  If they have the following</p>
  
  <p>ActiveFlag: "Y"</p>
  
  <p>Fiscal Year: 2016</p>
  
  <p>Group             BillableHours</p>
  
  <p>IT Consulting  1000</p>
  
  <p>HR Consulting 1500</p>
  
  <p>It would be understood that those total amounts represent the hours for every employee who was active for any part of FY2016 whether all 12 months or only 1.  If someone was active the year before, but weren't in 2016 they should not show up because I only want to interrogate the flags for the periods selected.</p>