Managing Databases

 

 

Managing Databases

 

You can use the Sample Database form the MySQL Tutorial Website to practice the activities illustrated in the links below.  

Here is a Link to Download the My SQL Tutorial Sample Database

Download mysqlsampledatabase-1.sql

 

 

 

Creating Database, Tables and Table Constraints

 

Create Database

http://www.mysqltutorial.org/mysql-create-database/ Links to an external site.

 

Remove / Dropping a Database

http://www.mysqltutorial.org/mysql-drop-database/ Links to an external site.

 

Creating Table in a Database

http://www.mysqltutorial.org/mysql-create-table/ Links to an external site.

 

Removing / Dropping a Table from a Database

http://www.mysqltutorial.org/mysql-drop-table Links to an external site.

 

 

RENAMING a Table in a Database

http://www.mysqltutorial.org/mysql-rename-table/ Links to an external site.

 

 

Adding Constraints to Table Attributes

 

The NOT NULL Constraint

http://www.mysqltutorial.org/mysql-not-null-constraint/ Links to an external site.

 

 

 

The PRIMARY KEY Constraint

http://www.mysqltutorial.org/mysql-primary-key/ Links to an external site.

 

 

The FOREIGN KEY Constraint

http://www.mysqltutorial.org/mysql-foreign-key/ Links to an external site.

 

 

The UNIQUE Constraint

http://www.mysqltutorial.org/mysql-unique-constraint/ Links to an external site.

 

 

The CHECK Constraint

http://www.mysqltutorial.org/mysql-unique-constraint/ Links to an external site.