Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 Database Design and Application Architecture
 how to design db table

Author  Topic 

collie
Constraint Violating Yak Guru

400 Posts

Posted - 2012-05-01 : 09:54:26
Hi,

I need to design a db with tables. Users are asked questions usually to rate between two similar products such as Android and iPhone.Each product will have an image. User clicks on image that he likes and the score is saved in a the db.
What I am not sure of is how to store the 2 products in the db for easy retrieval and inserts.Also I have to keep track of each product's score.
I want each day 2 different products compared. I want to insert into the db beforehand a list of the products to compare and each day it will compare 2 products.

I thought of the following 2 tables so far:
Scores table


Comparison table
ComparisonID QuestionID Asked Already (bit)
1 1 Yes/No
1 2
2 3
2 4

Questions table
QuestionID Question Score
1 iPhone 3
2 Android 7
3 SQL 199
4 Access 98




Thanks

boybawang
Starting Member

15 Posts

Posted - 2012-05-02 : 22:29:00
For easy advice on this matter you can reach for some database administrators who surely knows to update you for more security purposes.
Go to Top of Page
   

- Advertisement -