cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mohit_K
Helper I
Helper I

Dynamically FIltering Data Based on Custom Parameter

I have a data table like :-

idengineertestermanager
1102015
1203010
2151020
3201030
4101025
5302035
1403030
2153010
4503015
454520

 

 

I am applying Dynamic Row Level Security to my Power Bi reports and using that I am filtering the report based
on the logged in user which I am getting using USERPRINCIPALNAME() parameter.
I want to apply some more dynamic filters in my report but it is not based on USERPRINCIPALNAME(),
Is it possible to create a custom parameter and pass it to the reports and filter the report accordingly (in both power bi Desktop

and power bi Service).
Like CUSTOMPARAMETER = 'Engineer'
So the output becomes :-

idengineer
110
120
215
320
410
530
140
215
450
45

 

Similar output should be there for Tester and manager that is based on the value of the custom parameter we should be able to 

see the data.

1 REPLY 1
v-yalanwu-msft
Community Support
Community Support

Hi @mohit_K , 

 

According to the official document,Row-level security (RLS) with Power BI can be used to restrict data access for given users. Filters restrict data access at the row level,So ,it can’t be used Column level security.

https://ideas.powerbi.com/ideas/idea/?ideaid=3c6dd5d0-a2f9-44ae-a213-3a8c0d14dfd0,and you could vote for it.

 

Or, There are workarounds that might be able to assist. Check out this blog post on it 

 

Another idea is transpose the columns to rows in Power Query first, and then set the roles.

 

Reference:

https://www.bluegranite.com/blog/using-dynamic-row-level-security-with-organizational-hierarchies

 

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
PBI_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Get Ready for Power BI Dev Camp

Microsoft named a Leader in The Forrester Wave

Microsoft received the highest score of any vendor in both the strategy and current offering categories.

Get Ready for Power BI Dev Camp

Power BI Dev Camp - September 30th, 2021

Mark your calendars and join us for our next Power BI Dev Camp!

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Top Solution Authors