Forum Discussion

CHRBAR's avatar
CHRBAR
New Member
2 years ago
Solved

Table1 = USERPRINCIPALNAME() OR Table2 = USERPRINCIPALNAME()

Hi   I'm new to DAX and Power BI    I have a problem with RLS. I have a bunch of tables based on Business Central and Excel files. All are linked to the main table "Trades" including the 2 table...
  • Fowmy's avatar
    2 years ago

    CHRBAR 

    You can setup a RLS rule using a measure as follows, my table is Table33.

    Measure: NOTE:  "SAM" to USERPRINCIPALNAME() 

     

    VAR __User = "SAM"
    VAR __Result = __User IN ({Table33[Seller], Table33[Purchaser]})
    RETURN
        __Result

     


    My testing: