I’m trying to set up user-specific data visibility using row owners in my Glide app and need some assistance.
Here’s the scenario: My app serves about 20 separate companies, each identified by a unique company_id. In the “call_log” table, I have 12,500 rows of data containing entries for all companies. Each row has a company_id column that specifies the company the row belongs to.
I want to have flexibility when it comes to users and roles. For example, these would be the types of user configurations you might see in the app:
User1 can see the data for only one specific company.
User2 owns 5 of the companies, so he can see the data for these 5 companies.
User2 also has a manager (User3) for two of his companies, so he wants this manager to be able to view the data for 2 of the 5 companies.
I’m having trouble finding a topic that explains how to set this up. Any help would be appreciated!
That’s a shame. You should consider making the Users table a Google Sheet. This will give you the opportunity to define up to 9 roles per user, which should be useful in your case. With native Glide tables, you are restricted to one role per user.
If for example userA is the only one who has access to his 2 companies, this will have to be defined as a role?
I have many users that each own 2-3 separate companies, more than 9 users…
That is a bit of a deal breaker for me, unless I’m missing something…?
That’s okay, you would use the Company Name (or Company ID) as a Role, and in the case where a user owns 3 companies then they would have 3 roles. As long as a user doesn’t own more than 9 companies then you should be fine. If that was the case, then you may need to get a bit creative and group companies together.
Thanks Darren!
I do have a few users that will need to have access to more than 9 companies.
For example East region, West region account managers…
How would I do that?
Well like I said, you might need to get a bit creative. Perhaps you can group companies together - into regions? And then use the Region names as Roles/Row Owners.
Keep in mind, the maximum is 9 roles per user, not 9 roles in total.
You can have as many distinct roles as you want, but you cannot assign any more than 9 of those roles to any one user.
To put it another way, when you define the array column in the Google sheet, the maximum number of columns that Glide will allow in the array is 9.