Join tables across different schemas #2769
-
I was wondering if there was a way to join two tables beloning to two different schemas in one single request. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
It's not possible to do it directly right now, see #2346
If you have a See https://postgrest.org/en/v8.0/how-tos/embedding-table-from-another-schema.html |
Beta Was this translation helpful? Give feedback.
It's not possible to do it directly right now, see #2346
If you have a
schema1.table1
related(with foreign key) toschema2.table2
, then you could create a view ofschema1.table1
intoschema2
. PostgREST will discover the tables' relationship and you'll be able to do resource embedding on them.See https://postgrest.org/en/v8.0/how-tos/embedding-table-from-another-schema.html