Security Filter Syntax for Employee Department

Need some help getting a security filter setup for the following.

Employee table with one or multiple department codes (ex. table below)

[Employee], [Department], [EmployeeEmail]
John Doe, 10, JD@none.com
John Doe, 25, JD@none.com
Jane Smith, 10, JS@none.com

Property table with department responsible for management (ex. table below)

[PropertyID], [Department]
PropID1, 10
PropID2, 10
PropID3, 25

The security filter would allow users to see any property with a department code matching what is in the employee table for the users USEREMAIL().

Thus, John Doe would be able to see all properties with 10 or 25, while Jane would only see properties for center 25.

Thanks in advance.

Solved Solved
0 2 357
1 ACCEPTED SOLUTION

Steve
Platinum 4
Platinum 4

Try:

AND(
  ISNOTBLANK([Department]),
  IN(
    [Department],
    SELECT(
      Employee[Department],
      AND
        ISNOTBLANK([EmployeeEmail]),
        ([EmployeeEmail] = USEREMAIL())
      )
    )
  )
)

View solution in original post

2 REPLIES 2

Steve
Platinum 4
Platinum 4

Try:

AND(
  ISNOTBLANK([Department]),
  IN(
    [Department],
    SELECT(
      Employee[Department],
      AND
        ISNOTBLANK([EmployeeEmail]),
        ([EmployeeEmail] = USEREMAIL())
      )
    )
  )
)

With minimal coaxing this works like a champ!

Thanks Steve

Top Labels in this Space