Anda di halaman 1dari 1

Database -

Constraint - rules or restriction applied on the column of the table


Primary key - cannot be duplicate i.e. unique, cannot be null
Foreign key -
Course code - Name Fees
1001 B.tech 80000
1003 BCA 50000
Student
RollNo Name CourseCode
1 Ram 1001
3 Mukesh 1003
Unique key- cannot be duplicate, but can be null
Type of Primary key -
1. Autogenerated - 1,2,3,4,5,6
2. User-Defined - MCA-2003/23
B.Tech/2005/26
3. External PK - govt. agencies, i.e. PAN, AADHAR
4. Composite PK - using more that one columns

Anda mungkin juga menyukai