Hello all. I am trying to filter what differ...

Hello all.

I am trying to filter what different employees can see in the app.

Specifically I would like one crew to see only certain views and not others.

First question: is it possible to filter views, not just tables?

I am only seeing a security filter field in the table area.

However, I have some forms that use the same table, but I want one crew to see one form and not the other.

So if I can only filter the table and not the view, I donโ€™t think what Iโ€™m asking is actually possible.

I know I could clone the app and make different apps for each crew, but I donโ€™t want to have to regenerate and update multiple apps all the time.

This would be too much of a time suck for me during our busy season.

Second question: when putting an equation into the security filter (right now in a table), if I use the expression โ€œEmployees[Maintenance Crew Emails]โ€ am I telling app sheet to SHOW it to the Maintenance Crew or NOT show it to the maintenance crew??

This is unclear to me.

Am I even using the correct expression/equation?

Also, how do I test the app to see if the table or view is actually hidden to that crew?

Thank you for your assistance! Miranda

0 6 364
6 REPLIES 6

Hello @Miranda_Lubarsky Q #1.) I believe with the word โ€˜formโ€™ you wanted to mention โ€˜UX Viewโ€™. UX views have a Show_if property if you expand itโ€™s settings box to see more properties. You can use this property to show/hide UX views as per expression you set.

Q #2.) Security Filter expressions shall always evaluate to a Yes/No value. Therefore, your expression is not correct. Instead, the expression should be:

=CONTAINS(Employees[Maintenance Crew Emails], USEREMAIL())

Above expression will result with a Yes or No value, regarding if the userโ€™s email address is residing in Employees table, [Maintenance Crew Emails] column or not. If the eval is Yes, the use will be able to access the table.

To test if the table/view is actually hidden from the user; you should log in with that userโ€™s email address to you app. But if you test your expression in the Expression Builder after you have verified it, the result of the expression will give you an idea about it.

Hope my reply is explanatory. Please do not hesitate to ask more provided you need further help and/or explanation.

@Miranda_Lubarsky, I believe below help pages and material might also give you the overall idea:

appsheethelp.zendesk.com - Limiting users to particular tables, views, and actions

https://appsheethelp.zendesk.com/hc/en-us/articles/215789898-Limiting-users-to-their-own-data

https://appsheethelp.zendesk.com/hc/en-us/articles/205113918-Controlling-add-update-and-delete

https://www.youtube.com/watch?v=tkJhVgvj1ak Limiting users to particular tables, views, and actions appsheethelp.zendesk.com

@Levent_KULACOGLU Thank you !

I had read that first link that you send, but the language was confusing to me even after reading it several times which is why I put my question up here.

The way you explained it has clarified everything to me.

So to clarify, if I wanted to exclude (ie. prohibit) the Maintenance Crew from seeing that particular view or table, the equation would be =DOESNOTCONTAIN(Employees[Maintenance Crew Emails], USEREMAIL())

Is that correct?

@Miranda_Lubarsky correct expression should be:

=NOT(CONTAINS(Employees[Maintenance Crew Emails], USEREMAIL()))

@Miranda_Lubarsky If you want to negate any expression, you should be using NOT logical operator. The above expression will evaluate to No/False if the useremail is recorded in Employees table [Maintenance Crew Emails] column, yielding your Show_if or Security Filter eval to FALSE and will hide the table/view from the users whose email address in in that column.

However, I believe the best approach will be designing/contructing a ROLES table, where you can assign roles/privileges to each specific useremail (and you can even group them) and then write a bit more complex expression to read that access permission value. Let me show you what I mean. See attached img.

 
Top Labels in this Space