Relative Content

Tag Archive for supabasesupabase-js

Query with supabase with joins

I have 2 tables that I created in supabase the items and users
the items have a foreign key from the users ‘user_id’
in the users table I have the company_name
what I’m struggling with is how do I make a query for if the company name of this user is something specific then return to me all records from the items table else return to me only the items that are for the user that is viewing them.
I’m using the ClientJS from the supabase