cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
verri87
Regular Visitor

Send a report by email PDF to different users filter RLS

Hi 

 

I have created a report over salary information to the employee and need to send this report monthly to the employee by email as a pdf. Problem is that i need the PDF to show only data that is related to the employee, he should not see data for the other employees. So the filter in the pdf report should be by email. 

 

How do i add this rule? in desktop/ service and power Automate. 

 

I have 2 tables. "Dimemployee" which include user information like name, emails. And this has a many to many relationships to the table "facttimesheets" (this is where all the data i have used in the report in found) . They are conneteced with "Employeecode" witch can be found in both tables. Cross filter direction is "Both". Have not  checked on "Apply security filter...:" because that doesnt work. 

 

When managing roles. Theese two does not work when i try "view as" and writing an email. 

verri87_0-1652691000866.png

verri87_1-1652691103808.png

 

 

Please help me with photos so i better understand what youre saying. 

7 REPLIES 7
v-kalyj-msft
Community Support
Community Support

Hi @verri87 ,

Is your problem solved?? If so, Would you mind accept the helpful replies as solutions? Then we are able to close the thread. More people who have the same requirement will find the solution quickly and benefit here. Thank you.

Best Regards,
Community Support Team _ kalyj

it is not solved, but i think i need more admins access to the server to fix it. 

v-kalyj-msft
Community Support
Community Support

Hi @verri87 ,

Additionally, the box Apply security filter in both directions should be checked.

As per document "By default, row-level security filtering uses single-directional filters, whether the relationships are set to single direction or bi-directional. You can manually enable bi-directional cross-filtering with row-level security by selecting the relationship and checking the Apply security filter in both directions checkbox. Select this option when you've also implemented dynamic row-level security at the server level, where row-level security is based on username or login ID."

Reference: Row-level security (RLS) with Power BI - Power BI | Microsoft Docs

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks for the answer. I dont have the access to apply security filter at the server level, så i will check with the admins on that. I also tried to create the role with the email = USERPRINCIPALNAME() but nothing happend. In the power bi service the report was emty when i created the role... 

MFelix
Super User
Super User

Hi @verri87 

 

You shoul not use on the RLS "USERPRINCIPALNAME" this is a text and not the function try to replace it by USERPRINCIPALNAME()

 


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



verri87
Regular Visitor

Thanks for the answer. I dont have the access to apply security filter at the server level, så i will check with the admins on that. I also tried to create the role with the email = USERPRINCIPALNAME() but nothing happend. In the power bi service the report was emty when i created the role... 

Hi @verri87 ,

 

What do you mean by the report was empty when you created the role in the service? 

 

 


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
September Update

Check it Out!

Click here to learn more about the September 2022 updates!

Power BI Show Episode 10 Recap

The Power BI Community Show

Watch the playback when Amit Chandak, a Power BI Super User, demos how to use Field Parameters to make reports more dynamic.

Power BI Dev Camp Session 26

New Date - Check it Out!

Mark your calendars and join us on Thursday, October 6 at 11a PDT for a great session with Ted Pattison!

Health and Life Sciences Power BI User Group

Health and Life Sciences Power BI User Group

Power BI specialists at Microsoft have created a community user group where customers in the provider, payor, pharma, health solutions, and life science industries can collaborate.

Top Solution Authors