0

I have XAMPP with PHP 7.x on Windows 10.

When I install new XAMPP that supports PHP 8.1, there is no option to upgrade the older. And setup don't accept current XAMPP folder. I can backup htdocs folder and uninstall my older XAMPP.

How I a keep my MySQL databases? (or backup, if there id no way to keep them)

safineh
  • 80
  • 9
  • 1
    Please use `phpmyadmin` to export all your Mysql data into a sqldump file. – Ken Lee Nov 09 '22 at 02:56
  • simple export the database https://stackoverflow.com/questions/3031412/how-to-export-a-mysql-database-using-command-prompt and then simply update XAMPP !!! – OMi Shah Nov 09 '22 at 02:57
  • Does this answer your question? [How to export a mysql database using Command Prompt?](https://stackoverflow.com/questions/3031412/how-to-export-a-mysql-database-using-command-prompt) – Ken Lee Nov 09 '22 at 03:11
  • No, I want to **keep** databases, or if there is no way, backup all of my databases in XAMMP on Windows. Unfortunately `mysqldump` not worked here. – safineh Nov 09 '22 at 03:30
  • 1
    Search/Find mysqldump.exe. This file location maybe in **C:\Program Files\MariaDB x.y\bin\mysqldump.exe** Then add **C:\Program Files\MariaDB x.y\bin** path to your windows environment `PATH`. close any command prompt window and re-open it. Now your `mysqldump` should work. – vee Nov 09 '22 at 04:17
  • Solved by manually backup/restore. But why XAMPP installer has no **option to upgrade** older installed version?! – safineh Nov 10 '22 at 21:20

1 Answers1

0

I found mysqldump in c:\xampp\mysql\bin folder.

I used --all-databases parameter to dump all my dbs:

mysqldump -u USER_NAME -p PASSWORD --all-databases > BACKUP_PATH.sql

Tanks All.

safineh
  • 80
  • 9