Check out example codes for "grant all privileges mysql". It will help you in understanding the concepts better.

Code Example 1

GRANT ALL PRIVILEGES ON database_name.* TO 'username'@'localhost';

Code Example 2

/*
The GRANT statement is used to assign full control over specific database by providing all priviledge.
Follow below statement for assign priviledge to user
*/

Syntax: 
GRANT ALL PRIVILEGES ON database_name.* TO 'username'@'localhost';

Code Example 3

GRANT ALL ON *.* TO 'user'@'localhost';

GRANT GRANT OPTION ON *.* TO 'user'@'localhost';

Code Example 4

/*
The GRANT statement is used to assign full control over specific database by providing all priviledge.
Follow below statement for assign priviledge to user
*/

Syntax: 
GRANT ALL PRIVILEGES ON mydb.* TO 'myuser'@'%' WITH GRANT OPTION;

/*
I hope it will help you.
Namaste
*/

Code Example 5

CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';

Code Example 6

GRANT ALL PRIVILEGES ON `db_name`.* TO 'user'@'host'

Learn ReactJs, React Native from akashmittal.com