database design

  • I am planning to do a online question system and i am having some problems with my database design.

    I want to achieve this.

    Movie questions

    Q1. who directed the movie "braveheart"

    Q2. was titanic directed by steven spielberg

    True

    False

    Music questions

    Q1. who sung "take my breath away"

    Q2. robbie william was born in?

    England

    Scotland

    Ireland

    below is my tables. I have 5 tables, Type, Question, Choice, Questionset and Choiceset.

    Type

    typeid  typetext

    1       Movie questions

    2       Music questions

    Question

    questionid   questiontext

    1         who directed the movie "braveheart"

    2         who sung "take my breath away"

    3         was titanic directed by steven spielberg?

    4         robbie william was born in?

    choice

    choiceid     choicetext

    1     True

    2     False

    3     England

    4     Scotland

    5     Ireland

    6     None

    questionset

    questionsetid     typeid     questionid

    1     1     1

    2     1     3

    3     2     2

    4     2     4

    choiceset

    questionsetid   choiceid

    2     1

    2     2

    4     3

    4     4

    4     5

    4     6

    Is my above table design correct? could some one please correct me or guide me with this.

    many thanks

    sunny.

  • Wouldnt you just want to include the typeid in the question table? Would it make sense that a question could exist in both types?

    Andy

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply