How To Transfer A Database To The Server

Table of contents:

How To Transfer A Database To The Server
How To Transfer A Database To The Server

Video: How To Transfer A Database To The Server

Video: How To Transfer A Database To The Server
Video: Move a mySQL database from one server to another using export and import 2024, November
Anonim

The easiest way to transfer a database from one server to another is through text files. This procedure is described below for the most common MySQL DBMS in web programming. Almost all hosting providers offer phpMyAdmin for managing databases of this type, which allows you to carry out all the necessary operations directly in the browser window.

How to transfer a database to the server
How to transfer a database to the server

It is necessary

PhpMyAdmin application access

Instructions

Step 1

Prepare the files of the portable database for uploading to the sql server. If these files do not exist yet, then perform the operation of exporting all tables of the required database from the server on which it is stored.

Step 2

Load the phpMyAdmin interface into your browser. If you do not know the direct link, look for it in the database management section of the hosting administration panel. Logging into the interface requires authorization, but when logging in through the hosting panel, there may be enough data stored in the current session of your browser.

Step 3

Enter the name of the database to be transferred in the "New Database" field in the right frame of the interface and click the "Create" button. The application will send a CREATE DATABASE request and show you a message about the result of its execution.

Step 4

Create all database tables manually if you did not perform export operations, but received the files in some other way, and there are no CREATE TABLE queries in them. To check if the required instructions are in the files, open them with any text editor and use the search function for the query "CREATE TABLE".

Step 5

Click the Import link at the top of the right interface frame. To the right of the "Browse" button, the inscription "Maximum size" is placed in brackets and the weight limit of the uploaded file is indicated, set by your hosting provider in the server settings. If the database files do not fit into this limitation, then before loading, divide the strings of sql statements they contain into several files. The limit is rarely less than two megabytes, and this is usually quite enough.

Step 6

Click the Browse button, locate the first downloadable database file and click Open.

Step 7

Make sure that the character table specified in the "File encoding" field contains the characters used in the text fields of the loaded database. This is only necessary if the texts contain characters that are not contained in the English alphabet.

Step 8

Click the OK button at the bottom of the right frame to start downloading the file.

Step 9

Repeat the upload procedure if there are multiple files.

Recommended: