Primary Key (1 Viewer)

del

Member
Joined
Jul 8, 2002
Messages
412
Gender
Undisclosed
HSC
N/A
its to do with databases.
a primary key uniquely indentifies each record
 

Alex

Member
Joined
Jul 7, 2002
Messages
371
Location
Sutherland Shire
hence the name 'primary' as also in a relational database it enables tables and fields to be linked together. It should be in your textbook
 

gandalf

New Member
Joined
Jul 6, 2002
Messages
11
Location
Sydney
Gender
Male
HSC
1998
A primary key is an individual identify for each record within a table. Consider a database of HSC students within NSW. The state (ie NSW) could have two students with the same name John Smith. The database will include a field (usually called Student ID or your HSC candidate number) which is an individual number every student will have a DIFFERENT number. Therefore, one John smith may have a Candidate Number of 025739, while the other John Smith could be 025683. This way, the computer will be able to tell the difference between them.

This primary key becomes important when we link tables (using a relational database system) as the individual identifier will be use to form the links between the tables (the relationships). The student information (name address etc) may be linked to subject data (Biology, History etc) by the Primary key (in this case the Candidate number). Therefore we can set up a database which allows us to know that John Smith (025739) may be studying Biology, History and IPT, while John Smith (025683) is studying Japanese, Physics and Chemistry.
 

skeepe

New Member
Joined
Aug 2, 2002
Messages
14
I'm pretty sure that gandalf answered that question as well.

Primary key - 1st paragraph
Foreign key - 2nd paragraph

Could be wrong, it's been a while since I've done that stuff but I'm pretty sure that's what it is.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top