What is the difference between the Primary and Foreign key?
Answer Posted / dhirendra
Primary Key: This is a constraint which is always unique &
not null.
Foreign Key: This is a constraint which is just opposite to
Primary key. It can be not Null & can accept duplicate value
as well. Foreign key points to same table's primary key or
another table's primary key to make a relationship.
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
how to drop an existing index in mysql? : Sql dba
What is minus?
Explain the insert into statements in sql?
What is keys and its types?
Is nosql faster than sql?
First round ------------------- - Procedure - Packages - Views - Virtual tables - Can we use dcl with in function? - Joins and few scenarios - Triggers and its type - Pragma, type and its functionality - How to create db link in oracle - Materialized view - How to find duplicate values from table? - Cursor and its functionality - Write a script to display friday and its date from a entire year. - Exception Handling Second round ------------------------ Gave a scenario like. Need to write a function to perform. When user try to change a password. It must not be last five password and a given password can be combination of characters, symbols, upper and lower case.
Explain the difference in execution of triggers and stored procedures?
Do we need to rebuild index after truncate?
What do you understand by case manipulation functions?
Do ddl statements need commit?
Write the alter statement to enable all the triggers on the t.students table.
Does sql between include endpoints?
Is pl sql useful?
What is the difference between cluster and non-cluster index?
What is %type in sql?