what is primary key,unique key, foreign key? can u teach me
in simple language?
Answer Posted / nitin bisht
PRIMARY KEY: A tabLe can aontain only one PRIMARY KEY. It
Doesn't allow null values, it is used as Foreign Key In
Another Table(like Reference Key).
UNIQUE KEY: A Table may Contain one or more UNIQUE
constraints. Its aloow only one null value . Use this key We
maintain unique vales in the table.
FOREIGN KEY: A key used in one table to represent the value
of a primary key in a related table. While primary keys must
contain unique values, foreign keys may have duplicates. For
instance, if we use student ID as the primary key in a
Students table (each student has a unique ID), we could use
student ID as a foreign key in a Courses table: as each
student may do more than one course, the student ID field in
the Courses table (often shortened to Courses.student ID)
will hold duplicate values.
Is This Answer Correct ? | 123 Yes | 43 No |
Post New Answer View All Answers
What is the role of tester in discovery(in Checklist)?
What is difference between server and database?
Can you tell any two advantages of stored procedures?
What are the advantages of normalizing a database.
Given a table of Player which contains Sno and player name, write a query which finds all possible Table Tennis doubles pairings.
What is sharded database?
First input columns brand, mt, re values are ov, 1,re vg, 2,re wu ,3,re. Second input columns are brand, mt, cx their records are ov,4,vg ,5,cx Wu, 6,cx and third input columns brand, mt, rt values are ov,7,rt vg, 8,rt wu, 9,rt but my output is brand, re, cx,rt values are ov, 1,4,7 vg, 2,5,8 wu, 3,6,9
List various types of log-based recovery in DBMS.
what is the role of auditor in auditing data oriented applications?
Explain entity set?
5. Explain about relational algebra.
What are the tools used for backup and ticketing?
What are different types of resources?
WHAT IS THE PURPOSE OF TESTING INTEGRITY OF THE UNIVERSE?
What is lagging in DBMS ?