primary key is completely different from others, because it will used to sort the coulmn values in order and it is used to get the data in quick manner,moreover it will used in other table by referring as an foreign key....
@SamaC71311 жыл бұрын
this was a really great intro for those of us looking for some basic conceptual understanding thanks.
@cimode9910 жыл бұрын
The primary key is a key selected among keys (called also candidate keys), because it it is more robust and familiar than other keys.
@roughsealtd12 жыл бұрын
What you say about "sort" refers to clustering indexes; it's true with SQL Server and MySQL with InnodDB, not with Oracle for instance. Don't mix implementation and concept. And keys have nothing to do with speed (speed is a by-product of indexes that are used to implement constraints); besides, accessing data exclusively by primary key values is just a (key, value) implementation that has nothing to do with the relational theory. And foreign keys can also reference unique keys.
@roughsealtd12 жыл бұрын
The primary key is a key that is more equal than the others. All keys uniquely identify one row. But there may be several ones. If I had data about you, I could identify you by your first name, mid initial, surname, date and place of birth. Or your SSN. Or your KZbin username. Or a unique number I arbitrarily assign to you. I choose what I find most convenient to refer to you in my tables and call it primary key.
@monaghandavid14 жыл бұрын
The beginning is hilarious, great video!
@cimode9910 жыл бұрын
A primary key is a logical concept and has nothing to do with order physical concept.