android - How to Architect Database for Implementing a Commenting System -


i implementing commenting system in app. need database hold comments. if make row each post, have add comments in 1 collumn , split them identifier. please tell me better way this.

if 1 comments on app, comments part of chain of comments. store on every row this:

databaseid|positionofcomment|comment|discussionid 
  • databaseid - primary key of table (use google)
  • positionofcomment - increasing number 1, 1 first comment, 2 second , on
  • comment - actual comment user made
  • discussionid - needed foreign key in case have many different comment sections / discussions going on. in case have make discussions table. if there 1 chain of comments, not need this.

Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -