Types of Keys in DBMS
Keys are columns, or sets of columns, used to identify rows and link tables in a relational database. The main types are:
Super key: any set of columns that uniquely identifies a row. Candidate key: a minimal super key. Primary key: the candidate key chosen as the table's main identifier (unique, not NULL). Alternate key: a candidate key not chosen as primary. Unique key: a column or set kept free of duplicates with a UNIQUE constraint. Composite key: a key made of two or more columns. Foreign key: a column that refers to another table's primary key. Surrogate key: a generated identifier with no business meaning, as opposed to a natural key taken from real data.

