Forum Discussion

bcdobbs's avatar
bcdobbs
Community Champion
4 years ago

Tabular - Security Filtering Behaviour = None

Hi,
I came across "Security Filtering Behaviour = None" in Tabular Editor (both 2 and 3) and initially got excited that it would allow me to solve a specifc use case with RLS in order to leave all data available but just hide rows in one dimension table. (Specifically names). Suspect it may just not be supported (yet?) but wondered if anyone knew anything about what it is supposed to do.

I built this demo file

Connected to it with tabular editor (works in both the free version and version 3) and set the compatibility level to 1566 as it told me the property wasn't supported with levels below 1561.

 

Then on the relationship between the person table and the results fact table I set Security Filtering Behaviour to None

 

I was hoping it would filter that table but not pass anything to any other table.

 

Surprisingly it let me save back to Power Bi Desktop (had thought this would only get anywhere within XLMA connection to service).

 

WIthout RLS active it shows:

Note the 12 test results when nothing is filtered.

 

Now the odd bit! It didn't work but almost did...
Turning on one of the RLS rules gives:

 

Nothing shows however the number of results still shows as 12. In table view nothing is visible (before someone asks I turned off visual interaction).

 

Thoughts welcome.

6 Replies

  • bcdobbs's avatar
    bcdobbs
    Community Champion

    Have updated the link. Think it originally pointed to the version before I changed things in Tabular Editor. Sorry.

  • bcdobbs's avatar
    bcdobbs
    Community Champion

    So I've made it do what I wanted by setting the relationship between Person and Results as Many Many Cardinality with Person filtering results. (That reset the Security Filter = None so had to put it back). Everything now works as I wanted. Would love to know why though! Might be something to do with the Many Many relaitonship breaking table expansion? AlexisOlsonmarcorussosmpa01parry2k any ideas?



    Updated version with this in place here 

      • bcdobbs's avatar
        bcdobbs
        Community Champion

        Thanks Alexis, thought that was the case.
        What I'm trying to understand is the behaviour of the "Security Filtering Behaviour = None" and how/why it's behaviour changes with a limited relationship.

        I went back and watched some videos from SQLBI's Mastering Tabular. As  a result I wondered if actually the setting only kicked in with a bidirectional relationship. Have a look at:
        One to One Example 

        Relationships are setup as:

        and the security filtering behaviour between Person and Demographic is set to none.

         

        Connecting to the model with DAX studio as Group 1:

         

        Then running the following:

         

         

        EVALUATE
        	Results
        
        EVALUATE 
        	{ COUNTROWS ( Results ) }

         

         

        gives:

        (6 rows)

         

        vs

         

         

        Even thinking in terms of expanded table I can't come up with anything close to even a loose explanation of this.