Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
I have a Fact tablw which contain the sales data. And i got 2 dimension table. one for country and other for Sr manager names. Now i create a new table for access list. its is shown below.
I need to create the RLS based on the above list. As we can see that for Alex Sr Manager is showing as "All". IF "All" is coming then he should be able to see all the SR Manager name. Same in the case of Glen. For him both Country and SR Manager is coming as "All". So he should be able to see all the country and all SR manager. How can i achive this.
I tried something like this below. But when it is coming to "ALL" its coming as blank.
var _Restriction =
CALCULATETABLE(
VALUES( Access_List[Country] ),
Access_List[Email ] = USERPRINCIPALNAME()
)
var _RLS_Rest =
SWITCH(
TRUE(),
_Restriction = "ALL", TRUE(),
[Country] = _Restriction, TRUE(),
FALSE()
)
Return
_RLS_Rest
@unnijoy , I Usually Create a table with All , Name union with Name, Name and the join with table to get names when all use
All Guy
Guy Guy
Once UI gets the merged table, I have a column with the name, and you do not have to handle all
hi @amitchandak , i am not able to understand the solution that you gave. can we fix the below with out creating multiple tables.
var _Restriction =
CALCULATETABLE(
VALUES( Access_List[Country] ),
Access_List[Email ] = USERPRINCIPALNAME()
)
var _RLS_Rest =
SWITCH(
TRUE(),
_Restriction = "ALL", TRUE(),
[Country] = _Restriction, TRUE(),
FALSE()
)
Return
_RLS_Rest
User | Count |
---|---|
64 | |
60 | |
47 | |
33 | |
32 |
User | Count |
---|---|
85 | |
75 | |
56 | |
50 | |
45 |