How to import database via phpMyAdmin in cPanel? (Video)

 

Importing a database using phpMyAdmin in cPanel is a straightforward process that allows you to restore or migrate databases.

Follow the steps below:


Step 1: Log in to cPanel

  1. Open your browser and navigate to your cPanel login page (e.g., https://yourdomain.com:2083).
  2. Enter your username and password, then click Log in.

Step 2: Access phpMyAdmin

  1. Scroll to the Databases section in the cPanel dashboard.
  2. Click on phpMyAdmin.

Step 3: Select the Database

  1. In the phpMyAdmin interface, locate the left-hand sidebar that lists all the databases.
  2. Click on the name of the database where you want to import the data.
    • If the database does not exist, create it first via MySQL Databases in cPanel.

Step 4: Open the Import Tab

  1. With the database selected, click the Import tab at the top of the phpMyAdmin interface.

Step 5: Upload the Database File

  1. In the File to Import section, click Choose File.
  2. Select the database file from your local computer.
    • The file should typically be in .sql format. If it is compressed (e.g., .zip or .gz), phpMyAdmin can handle the decompression.
  3. Optional: Adjust import settings, such as the character set (default is usually utf8) or compatibility options, if required.

Step 6: Start the Import

  1. Scroll to the bottom of the page and click Go.
  2. phpMyAdmin will begin importing the database.
    • The time required depends on the size of the database.

Step 7: Verify the Import

  1. After the import completes, you’ll see a success message if it was successful.
  2. Navigate to the Structure tab to verify that the tables and data have been imported correctly.

Tips for Importing Databases

  • Database Size Limit: Some hosting providers impose upload limits for phpMyAdmin. If your database is too large, consider using SSH or contacting your hosting provider for assistance.
  • Error Handling: If you encounter errors (e.g., max_execution_time or max_file_size), ask your hosting provider to increase the limits or split the SQL file into smaller chunks.
  • Backup Existing Database: Before importing, create a backup of the current database to avoid accidental data loss.

By following these steps, you can easily import a database via phpMyAdmin in cPanel and ensure your website or application has the necessary data to function correctly.

  • 0 משתמשים שמצאו מאמר זה מועיל
?האם התשובה שקיבלתם הייתה מועילה

מאמרים קשורים

How to create a database in cPanel? (Video)

  Creating a database in cPanel is an essential step for hosting dynamic websites or...

How to rename a database in cPanel? (Video)

  cPanel does not provide a direct option to rename a database through its interface....

How to delete a database in cPanel? (Video)

  Deleting a database in cPanel is a straightforward process. Follow these steps to...

How to Create a Database Username in cPanel? (Video)

  Creating a database username in cPanel is essential for managing access to your databases....

How to add a user to a database and add privileges? (Video)

  Adding a user to a database and assigning appropriate privileges is crucial for managing...