2
votes
2answers
477 views

Database model for keeping track of likes/shares/comments on blog posts over time

My goal is to keep track of the popular posts on different blog sites based on social network activity at any given time. The goal is not to simply get the most popular now, but instead find posts ...
1
vote
3answers
140 views

Storing a drawn graph information in database for web application

Well while developing a web application that allow users to draw graphs (flow charts, ER diagram , UML, .... etc) the information of drawn items and their relation to each other and position on canvas ...
3
votes
1answer
162 views

Database Schema for Pricing Products (packages, promotions, qty based, limited time offer…)

I'm working on a new point of sale for a company that products for different prices depending on the product mix. All products have a base price. To explain my problem, I will use the following ...
0
votes
3answers
179 views

How to maintain user relationship when user unfollows another user

I have a table of user relationship which stores who follows whom, the table structure is as follows -id -follower -following when someone follows any other user, I add a record with follower user ...
5
votes
4answers
234 views

Putting audit functionality into the database

Our database does not have any audit functionality. It does not records who inserts the record or who who changes it It does not keep a history of the changes made Nothing can be restored if ...
3
votes
1answer
282 views

What are the advantages and disadvantages of storing the number of comments in an integer column vs. calculating it on the fly?

Let's take CodeReview page as an example. If you go here, you will see the list of the questions with their vote numbers and comment numbers Now, I am wondering if these numbers are calculated on the ...
4
votes
2answers
487 views

How to design a website with search capabilities?

Suppose you want to create a web page with some search capabilities over a database. Search has to be restricted both on some categorization of data and open text given by the users. Functional and ...