Can any1 help me?

  • I am a novice at creating databases as well as Sql. Can anyone help by pointing me in the right direction by way of table and column names for the following problem. Me being a rookie thought that I would need just 3 tables but I have been told that 6 or 7 will be needed to stop many to many relationships occurring.

    The tables need to contain the following information:

    ·         The first and surname of each pupil

    ·         A pupil id

    ·         The area the pupil resides in

    ·         The school the pupil attends

    ·         The address of the school

    ·         The hobby the pupil takes

    ·         A description of the hobby

    ·         How often they do the hobby

    ·         The location of the hobby.

    You may need to add additional data elements into the tables to give a good structure to the table, for example, we have to contain the address of the school, do you want to store it as ADDRESS or ADDR1, ADDR1, TOWN, CITY, POSTCODE it is down to you to determine the best way to structure the data.  You may also need to add additional data in order to allow the links between the tables to be correct, remembering that FK goes to a PK in another table so consider if you wish to link pupil to hobby by hobby description or add an additional column called hobby_id.

     

     

  • I can confirm the 6-7 but I don't have time to design all this.

     

    Why are you not hireing a programmer to do this for you?

  • ???

    That looks like a homework problem?

    Steve G.

  • That too .

  • I would recommend looking at a book by Chris Date on FK stuff (or any basic Database design book) to help you get the normalisation of the tables correct.

    Or, for a small fee, I'll do the design for you.

Viewing 5 posts - 1 through 4 (of 4 total)

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