tayyab ahmed
tayyab ahmed

Reputation: 147

How to add user in phpmyadmin

I want to know how to add user in phpmyadmin , I have done some research but didnot find the proper answer. I am unable to find the privilege section in phpmyadmin so that i can add a username and password . I am working on hosting and i cant see the privilege section in my phpmyadmin main's page.

Sorry for the inconvenience my english is weak

Upvotes: 10

Views: 116631

Answers (6)

user281681
user281681

Reputation: 405

I can never get the hang of that phpmyadmin interface. One easy way to get around it is to click on the 'mysql' database, then click on the link SQL to write your own query:

GRANT ALL PRIVILEGES ON dbname.* TO your-new-user@host-ip IDENTIFIED BY 'his-strong-password';

When the query has run,

FLUSH PRIVILEGES;

and run that query as well.

Both your user has been created and the privileges have been set. Instead of using the ip address, you can also add a host name if that suits you better.

Upvotes: 0

Y.Lu
Y.Lu

Reputation: 71

I was successful in adding user using the "User accounts" tab in the main view (as posted by Kadaiser). All privileges are global. It does not provide a way to grant privileges on any specific database. Also, one must specify the host name of the user for database connection to work (i.e. so and so@% presented connection problems).

Upvotes: 1

Parth
Parth

Reputation: 215

phpMyAdmin does not handle user management, rather it passes the username and password on to MySQL. create mysql User.

and If you mean, users controlling their own database, go here.

Upvotes: 3

Lucia
Lucia

Reputation: 13597

Select the database on the left, then:

enter image description here

Upvotes: 8

Kadaiser
Kadaiser

Reputation: 228

phpMyAdmin does handle user management, The fourth tab in the main view, "User accounts". In there, you have the section, "New", there you can add new users.

Upvotes: 1

Digital Chris
Digital Chris

Reputation: 6202

From https://wiki.phpmyadmin.net/pma/user_management :

To create a new user, click the Add a new user link near the bottom of the Privileges page (you must be a "superuser", e.g., user "root").

(emphasis mine)

Upvotes: 5

Related Questions