I am thinking about scaling issues with many-to-many join tables.
I have a constructed example as following:
- Many users have many wishlists.
- On every wishlist are many items.
If I scale this table to million of users the wishlist_items table will get very big:
- 1000000 users
- 100 wishlists for every user
- around 1000-10000 items on every wishlist (bad example, but you get the point)
Therefore table size for the join table will be:
users * wishlist_per_user * items_per_wishlist
I think this is a very common situation in RDBM design. I am afraid that this users * wishlist_per_user * items_per_wishlist relation will grow out of bound.
Are there any similar experiences with such big tables and how to query them fast? How would I design my tables to prepare for better scaling?