MySQL Script
#Create Database
CREATE DATABASE mydatabase CHARACTER SET utf8 COLLATE utf8_general_ci;
#Create New User
CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';
#Set Permission
GRANT ALL PRIVILEGES ON mydatabase. * TO 'newuser'@'localhost';
#Refresh Privileges
FLUSH PRIVILEGES;