What is the difference between the Primary and Foreign key?
Answer Posted / nitin
Primary key uniquely identified a record in a table and dont have null values. Also when we create primary key an index is automatically created for primary key.
On the other hand foreign key is used for referential integrity, foreign key can points to primary key in other table and moreover index is not created for foreign key.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can we insert data into materialized view?
How do I clear the screen in sql plus?
how many ways we can we find the current date using mysql? : Sql dba
how to get @@error and @@rowcount at the same time? : Sql dba
What is group function in sql?
What is nvarchar max in sql?
what is sp_pkeys? : Transact sql
Is there a 64 bit version of ssms?
What is trigger in pl sql with examples?
How to get unique records from a table?
What are the different type of joins in sql?
What is sql*loader?
Can we use loop in sql?
What is %s in sql?
How we can update the view?