Using PHPmyadmin (and shell command)
To create a database, it is helpful to have a graphical interface. One good instrument for that is called phpMyAdmin. And installing it in a local machine is easy too. Unzip the downloaded file and copy it to the www/phpmyadmin directory.
It is easy to launch it: just browse to http://localhost/phpmyadmin/. If you are in a hosting environment this operation is not necessary because the host will provide a phpMyAdmin interface for you.
The interface allows you to:
1. Select an existing database
1. Create a new one

If you are working on a local machine don't worry about the warnings.

We are interested in the 3 first menu voices:
Structure: Shows the table list and allows us to:
- Browse table content
- Select table values
- Insert new data in the tables
- Properties: Show table structure
- Drop: Delete table (ATTENTION!!!)
- Empty table content (ATTENTION!!!)
SQL: This part of the menu allows us to change data in the database structure, doing that is easy, you only need to browse your PC directory and choose the right file

The export function is important for backup.
Structure Only: Saves only the database structure but not the data
- Structure and data: Saves structure and data
· Data Only: Saves only data
· XML: Exports in XML format
DATABASE IMPORT USING THE SHELL
mysql database -u user -h host .p pass < file.sql
- database = database name
- user: user name
- pass: password
- file.sql: file name
DATABASE BACKUP USING THE SHELL
mysqldump -c -hlocalhost -uusername -ppassword nome_db > dump.sql
- hlocalhost = db HOST
- uusername = USERNAME
- ppassword = password
- nome_db =database name
dump.sql = name of the file saved
The -h, -u and -p parameters and data don't have spaces. User mike -> -umike