Friday 6 September 2013

M1

Referential integrity


Ref Integrity

from what i understand of referential integrity it is when you have all of the data required of a relation
what this does is it stops you putting any null values into the database or it will not function properly
for example when you sign up for an email account you need to fill out all of the boxes such as name and date of birth and alternative email address if any of these boxes are not filled out it will bring up an error message that will stop you from continuing with the information and will ask you to fill out the missing information and will often state "all fields are required" this means that you will need to go back and fill out the null values because if there is a null value in a database then it would not function properly




Primary key

there are different keys such as primary and foreign keys the primary keys are for keeping track of data when there is more that one piece of data that is similar for example in the library they will have multiple poppies of the same book but they still need to catalog them differently so they will use what i believe to be a bibliographic catalog this means that they will have 10 copies of Alice adventure in wonderland and these ten books will all have the same key such as ZTUE and then they will have a number so the books would go from ZTUE01 to ZTUE10 this is one of the earliest and forms of a database but using the primary keys means that you can keep track of multiples of the same data




Foreign key

the foreign key is the data that is in the columns this is the data that is used to connect the data and show the relationships between it for example on IMDB you can look at a movie and look at the actors that are in that movie and from there you can look at what others movies they have been in this is how you move from one column to another using the relationships between the foreign keys




1 comment:

  1. www: a good accurate start.
    ebi: you split the text up into 3 sections:

    Ref Integrity
    Primary key
    Foreign key

    Try and find some images to back up your descriptions.

    ReplyDelete