Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Exporting PHPMyAdmin database to live server.

Options
  • 07-12-2016 9:19pm
    #1
    Closed Accounts Posts: 5,482 ✭✭✭


    I have been working on a college project for the last while, and I need to deploy it . My database is with phpmyadmin, so my question is how do a export this to use with my application when it's live.


Comments

  • Registered Users Posts: 6,252 ✭✭✭Buford T Justice


    mysqldump -u [username] -p [database_name] > [location-to-save.sql]
    
    next prompt will ask for your password, assuming you have one set.


    On the live site, its a case of:
    mysql -u [username] -p [database_name] < [location-to-file.sql]
    
    next prompt will ask for password, assuming you have one set.

    Have you command line access to both databases?


  • Registered Users Posts: 6,501 ✭✭✭daymobrew


    Or, if you are used to using phpMyAdmin, export to SQL from there and then go to phpMyAdmin on the live server and import. Obviously this relies on the live server having phpMyAdmin.

    While this is slower than using the command line that Buford has suggested, it sounds like you may be more comfortable with a web interface like phpMyAdmin.


  • Registered Users Posts: 6,252 ✭✭✭Buford T Justice


    daymobrew wrote: »
    Or, if you are used to using phpMyAdmin, export to SQL from there and then go to phpMyAdmin on the live server and import. Obviously this relies on the live server having phpMyAdmin.

    While this is slower than using the command line that Buford has suggested, it sounds like you may be more comfortable with a web interface like phpMyAdmin.

    Remember, you are limited to the size of the database doing it this way.


  • Registered Users Posts: 6,501 ✭✭✭daymobrew


    Remember, you are limited to the size of the database doing it this way.
    True - though gzip can help for upload size issues.

    I suggested the simpler web interface because OP says My database is with phpmyadmin instead of "I have a SQL database".


Advertisement