I have a database on my computer. How can I upload it on cpanel?
The construction of a website is a process that can be done either into a real (online) server or in a local (offline) server, in a personal computer for software development purposes (development).
The construction of your website on your PC gives both flexibility, speed and independence in the creator, secondly, creates the need to transfer the webpage into a real server, when the development phase completes (development).
If you are not familiar with the concept of Database see some basic information about what are the databases and why we need them.
To transfer a database from your local computer to the online server it should initially be exported (export) to a file from the local server and then this file has to be imported (import) at the online server. To make the export / import of the database we will make use of the application phpMyAdmin which is installed on all servers of IP.GR as well as in most of the known servers that are used in personal computers for development (wamp or xampp in windows, mamp in mac etc).Separate your actions in two phases, the extraction phase from local server and the importation phase to the online server.
Exctracion phase from local server
The execution of the steps that follow presupposes the existence of a local server and an already created database.
Open the address: https://127.0.0.1/phpmyadmin on your browser.
In the left menu you can see the databases that exist in your installation. Click the database you want to export (export). In our example is the example_db database.
Click the Export option.
Select Custom - display all possible options and Output zipped.
Click the GO button at the end of the page and save the zip file, it will generate, on your computer.
Import database to an online server
To import a database to an online server requires that you have a hosting package in real server. If you do not have a package see how you can get your own hosting subscription in IP.GR
If you own a hosting package follow these steps:
- Login to cPanel
Click the phpMyAdmin option in the Databases category.
Select the empty database that you want to import to, the database which previously you exported from the local computer. In our example is the online_db database.
Click the Import option.
Select the file with the database that you want to upload (the one that you exported from your local server).
After some waiting import is completed .