Remote Access of DataBase in Different Host by use of following comment
mysql > GRANT ALL PRIVILEGES ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
Example :
mysql > GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY ‘root’;
above command gives access for all privileges. we can grand specific privilege also.
1. Select permission
mysql> GRANT SELECT ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
2. Select and update permission
mysql> GRANT SELECT,UPDATE ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
mysql > GRANT ALL PRIVILEGES ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
Example :
mysql > GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY ‘root’;
above command gives access for all privileges. we can grand specific privilege also.
1. Select permission
mysql> GRANT SELECT ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
2. Select and update permission
mysql> GRANT SELECT,UPDATE ON *.* TO 'USERNAME'@'%' IDENTIFIED BY ‘PASSWORD’;
No comments:
Post a Comment