Β© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabaseβ€’3y agoβ€’
11 replies
Geo_bot

How do I join tables that don't have a foreign key relationship with JS

I'm effectively trying to copy this SQL query
SELECT profiles.name, stories.title, stories.description, stories.created_on FROM stories INNER JOIN profiles on profiles.id = stories.user
SELECT profiles.name, stories.title, stories.description, stories.created_on FROM stories INNER JOIN profiles on profiles.id = stories.user

into the javascript api. profiles and stories don't have a foreign key relationship but profiles.id and stories.user both reference auth.users.id
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

inner join without foreign key relationship
SupabaseSSupabase / help-and-questions
3y ago
Query table with multiple cols with same foreign key. Join tables.
SupabaseSSupabase / help-and-questions
3y ago
Foreign key relationship isn't one to one
SupabaseSSupabase / help-and-questions
3mo ago
How do I filter a table with foreign key using postgrest?
SupabaseSSupabase / help-and-questions
4y ago