Connection URL of phpmyadmin
31,538
This is the connection URL for access Phpmyadmin MySql server:
Class.forName("com.mysql.jdbc.Driver");//Set driver
connection = (Connection) DriverManager.getConnection("jdbc:mysql://db_ip:3306/dbName",user_name, password);
//Get Connection
If you got below message:
#1130 - Host 'machine name' is not allowed to connect to this MySQL server
Then you need to execute below query:
CREATE USER 'root'@'%';
GRANT ALL PRIVILEGES ON * . * TO 'root'@'%' ;
GRANT ALL PRIVILEGES ON `root\_%` . * TO 'root'@'%';
This query creates the root user with all privilege and password is null.
Edit:
This is the reference may help you:
Author by
codeofnode
Day : Coding for network management software. Eve: Workout to keep my body and mind fit Night: For templist, allrounder and my other open source projects
Updated on July 05, 2022Comments
-
codeofnode almost 2 years
Can any body help me to get the connection url of the MySQL database on the server of phpmyadmin. I want to access the database remotely.
Please note that the database is not on my local pc hard disk.
Thank you.
-
codeofnode over 11 yearsI am using the url : jdbc:mysql://69.187.151.5:3306/DCQ But i am getting the error as i commented in my question.
-
Dhinakar over 11 yearsI think this issues arises for mysql network permission. Refer this link [cyberciti.biz/tips/…
-
codeofnode over 11 yearsm sorry to ask silly question, but can u tell me where to execute the above query.. Plz reply..
-
Dhinakar over 11 yearsOpen browser and type 69.187.151.5/phpmyadmin. Click SQL tag. Copy and paste this query. Click Go to run.
-
codeofnode over 11 yearsi ll be back with results with actions as you said in 2 minutes.. thanks.. :)
-
codeofnode over 11 yearsi have already a user with root.. and but have some password.. Then what query should i execute.. plz reply the query with password.
-
Dhinakar over 11 yearsI think no need to execute this queries for your problem. I have attached the link with the answer. Kindly refer it.
-
codeofnode over 11 yearsThe link is quit confusing and the answer in the link says various points to check.. i am quit sure that every thing mentioned in the answer is perfect in my situation.. but yet i am getting this error.. :(
-
Dhinakar over 11 years