In order to be able to use a database, we need to create a new database, give access permission to the database server to a database user and finally grant all right to that specific database to this user. And if the user does not exist yet, we need to create a new one.

To create a new database:

create database newdatabase;

To create a new user:

create user ‘newuser’@'localhost’ identified by ‘newuserpassword’;

And grant all right to that specific database to this user:

grant all privileges on newdatabase.* to newuser@localhost;