mysql grant
snippet in sql

mysql add user with all privileges

user377

CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON * . * TO 'newuser'@'localhost';
FLUSH PRIVILEGES;

mysql grant all privileges to a user

user7646

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

create database and grant user rights mariadb

user4051

create database [DB name];

CREATE USER '[DB_User_Name]'@'localhost' IDENTIFIED BY '[DB_Password]';
GRANT ALL PRIVILEGES ON [DB_Name].* TO '[DB_User_Name]'@'localhost';

show grants for 'demouser'@'localhost';

FLUSH PRIVILEGES;

grant all privileges mysql

user8145

/*
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';

grant all priviledges to mysql user

user535

/*
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
*/

mysql grant

user2885

if(curl_exec($ch) === false)
{
    echo 'Curl error: ' . curl_error($ch);
}
else
{
    echo 'Operation completed without any errors';