Jump to content
Larry Ullman's Book Forums

Ch. 17 Forums (Data Base Question: How to add a 'like' table?)


Recommended Posts

Hello Larry,

I thought CH 17 Forums was well put and easy to implement. If I were to add a Like functionality to the database design. Then it would look as follows:

posts_table

  • post_id
  • thread_id
  • user_id
  •  etc

thread_table

  • thread_id
  • etc

user_table

  • user_id
  • etc

like_table

  • like_id
  • post_id
  • user_id
  • etc

 

This database design looks normalized, but the 'like_table'  would hold all likes for all posts? This seems like a table that would be very heavily populated and queried? What do you think about this Larry? Thanks I appreciate your response to these forums.

Link to comment
Share on other sites

 Share

×
×
  • Create New...