Is there a way to run a select query linking a table and a view?
I have a view which is based on "table_2" which has a foreign key to "table_1" is there a way I can run a select query to join them from react?
Trying to run:
However I get an error "could not establish a relationship between table_1 and table_2".
Looking at this page: https://supabase.com/blog/postgresql-views it says that a view behaves like a typical table and you can join with it and stuff, but maybe that's only backend joins rather than through the select function in js?
Trying to run:
await supabase.from("table_1").select(
id,
...columns,
table_2 (
table_2_id_col
...columns
)
)However I get an error "could not establish a relationship between table_1 and table_2".
Looking at this page: https://supabase.com/blog/postgresql-views it says that a view behaves like a typical table and you can join with it and stuff, but maybe that's only backend joins rather than through the select function in js?
