primary key - A column in a table that uniquely identifies a row in a table
foreign key - A column in a table that does not uniquely identify rows in that table, but is used as a link to matching columns in other tables.
composite key - A primary key that consists of more than one column
For example consider the following simplified table structure:
Table 1: Employee
Columns: Employee_ID (primary key), Employee_Name
Each Employee_ID will mean one unique employee
Table 2: Employee_Salary
Columns: Employee_ID, Salary, Salary_Date
This table will have the salaries for all employees for all different months. So there will be multiple occurances of the same Employee_ID in the table.
Here Employee_ID is the foreign key
Now in the second table, we can declare the combination of the Employee_ID and the Salary_Date as a Composite Primary key. Because no employee will receive salary more than once in a month, the so Salary_Date and Employee_ID combination will always be unique.