Forum Academy Marketplace Showcase Pricing Features

Best database design for tournament

Hi Bubble Community,

I’m designing a web app to automate a tennis tournament. The design consists in players joining a tournament (created by an admin role) and then within the tournament confirming their assistance for a certain period (e.g- November/December 2021). Once the period starts, every week players confirm their assistance to that week and based on the players confirmed (e.g- 20/25 subscribed players), groups of 4 players are automatically defined.

I currently thought of having the following databases

  • Users - users registered in App
  • Tournaments - tournaments created
  • Tournament_Users - users subscribed in a tournament
  • Tournament_Period - users confirmed for the upcoming period
  • Tournament_Week - users confirmed for the upcoming week, within the confirmed period

My questions are the following:

  1. Does this design make sense? Any suggestions on best practices?
  2. For the Tournament_Users, would you recommend for each user to have a list of the tournaments they are subscribed to, or the other way around, for each tournament a list of users subscribed.
    2.1. How would you display a dropdown list to the user showing all of the tournaments they are subscribed to? I tried to do a Search For Tournament_Users where Created by = Current User, but it is not working. Any suggestions?

Thanks a lot in advance, hope someone can help :slight_smile: