© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabase•4y ago•
108 replies
iStun4Fun

How to get current user analytics based on 3 tables

I have 4 tables

auth
user
music_label
royalties

Need to get the SUM(royalties.total_revenue) of:

auth.uid where
royalties.label_id = music_label.owner = auth.user

already reffered the royalties.label_id with music_label.id

how to get the current sum for the auth.user ?

i'll drop a table model so you can check and a diagram if you need it to help me out
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
Next page

Similar Threads

get Stream of current user
SupabaseSSupabase / help-and-questions
4y ago
Get property of current user
SupabaseSSupabase / help-and-questions
4y ago
How to get current user data server side (next.js middleware)
SupabaseSSupabase / help-and-questions
4y ago
Joining 3 tables
SupabaseSSupabase / help-and-questions
3y ago