User Data Access limitation in all Tables via Security Filter

Hi together,

I have created an app that is supposed to be used by several vendors, the DB is managed via a GSheet:

Scenario:
Tables:

  • Company
  • Vehicle
  • Driver
  • User
  • Documents
  • Incidents

All Tables contain linked data, as I have included in each Table a column with “CompanyID” and referenced it to the main one maintained in the User table.

  1. How can i manage the security filter on all tables that it only shows all the entries with the specific CompanyID of the User even though some of the tables do not contain User data but just the company ID as a link? I am a bit lost here and do need a starting point on how to manage the formula.

  2. As a second step data in each View shall be filtered based on a specific role of the user that is using the app, this role is also maintained in the user table.

Thanks so much for any help.
Cheers,
Sebastian

Hi @Sebastian_Henk
There is a search facility at the top of the screen/page that can be helpful.


https://community.appsheet.com/search?q=users%20security%20filters

2 Likes
[COMPANY_ID] = 
LOOKUP(
	USEREMAIL(),
	"USERS",
	"EMAIL",
	"COMPANY_ID"
)

That’s totally related how your tables are structured depending on the user role. Can you elaborate this?

2 Likes

One way is to use the horizontal technique described in this article…

2 Likes

Many thanks! This already helped a lot!

1 Like

You’re welcome.