Hi

Just curious to see what everyone else thinks - its a small issue, but can be applied to a variety of situations.

The website Im building allows people to rate news stories, I was just wondering if you would record each vote individually, or open a line in the table for a product and then +1 every time someone votes/rates the story.

Thoughts?

Recommended Answers

All 2 Replies

If all I needed to know is how many votes a story received I would update one field with +1. If I had the need to distinguish one vote from another (like source IP, user name, date/time, etc.), I would have no choice but to record them in a separate table as it would be a one-to-many relationship.

Member Avatar for rajarajan2017

Increase by 1 in the relevant news or story table. Thats it! There is no need of username who is voting. waste of time. This is my suggestion.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.