Forum Discussion

acbg's avatar
acbg
Resolver III
6 years ago
Solved

Row Level Security - Service Principal

I am not able to see Service Principal when trying to add a new member in Row Level Security. Is it possible to add Service Principal in the screen below:
  • v-juanli-msft's avatar
    6 years ago

    Hi acbg 

    I don't find any documents how to add service principal in row level security.

    It is said that :

    To get started with service principal, you need to register a server-side web application in AAD to use with Power BI.

    Note that the new AAD web application created in step 1 must be added to one of those security groups, to be able to authenticate to Power BI as a service principal.

     

    Steps to use Service Principal:

    https://docs.microsoft.com/en-us/power-bi/developer/embedded/embed-service-principal

     

    Best Regards

    Maggie

     

  • acbg's avatar
    acbg
    6 years ago

    v-juanli-msft 

     

    Thanks for your help.

     

    Was able to figure it out: CustomData was included in our code eventhough it was set to null  and once it was removed everything started working.

     

    The only items that should be passed in RLS is Username, Role and DatasetID if the dataset is in Power BI. Username should be  client/end username.

    On the Power BI model, create the role and just set the Username field to filter to username().

     

    For Analysis services CustomData needs to be included. Username would be SPN and CustomData would be client/end username.

    RLS in Analysis services, Username should be set to CUSTOMDATA().

     

    Hope this helps anyone else running into this.