Almost every site that isn't just static pages needs a database. In cPanel you create one in about a minute - and there are three separate things, which is where most confusion starts.
The three things you need
| 1 |
The database - where the data lives.
|
|
| 2 |
The user - the account that connects to it. It is not the same as your cPanel user.
|
|
| 3 |
The permission - linking the user to the database. Without this step, the application connects and gets "access denied".
|
|
Creating them
| 1 |
In cPanel, open MySQL Databases.
|
|
| 2 |
Under Create New Database, type a name and create it. cPanel prefixes it with your account name automatically - that full name is what the application needs.
|
|
| 3 |
Further down, in MySQL Users, create a user with a strong password. Save that password now; it won't be shown again.
|
|
| 4 |
In Add User To Database, pick the user and the database, and grant ALL PRIVILEGES.
|
|
Using phpMyAdmin
phpMyAdmin, also in cPanel, is where you look at and edit the data directly - useful for changing a setting, fixing a table or exporting a copy.
| 1 |
To export, choose the database, open Export and confirm - the .sql file downloads.
|
|
| 2 |
To import, use Import and pick the file. Large files may fail here; if so, send us the file and we import it from the server side.
|
|
|
Take a backup before editing anything in phpMyAdmin. There is no undo. A wrong query in the wrong table takes the site down instantly - and the fastest recovery is yesterday's backup.
|
Reaching the database from outside the panel
phpMyAdmin does the day to day. When you need a real client, or PostgreSQL instead of MySQL, these are the two.
Reaching it from outside
When something goes wrong
RECOMMENDED PRODUCT Web hosting with cPanel Domain and SSL included, daily backups and the panel you already know. from $6.59/mo (3-year plan, with coupon) See plans |