PHPMyAdmin is showing some strange results when I go to export a table as SQL. If I go to the main database and select Export (i.e. the whole database) at the top it works as expected but when I go to a table and try end export just that table, there is no SQL option in the select list on the "Format:" section.
I am using Server version: 5.5.62(MySQL) and phpmyadmin 4.8.4. This is server wide (happening on all db's on this server)
There is a workaround, I can go to the main database level and export all and only tick the options of the tables I want but want to get this to work.
I have read about a max_input_vars setting but if this was the case, it would not export the whole DB, this just happens at a table level.
Thanks in advance
The fix does work, have applied it to many servers at this point.
Fix # 14775 : edit 'Export.php'
Resolution:
Connect to the server via SSH.
Open file:
/usr/local/psa/admin/htdocs/domains/databases/phpMyAdmin/libraries/classes/Display/Export.php with a text editor.
Note: for Windows, it will be
%plesk_dir%admin\htdocs\domains\databases\phpMyAdmin\libraries\classes\Display\Export.php.
Find line /* Scan for plugins */
Add the following above the line:
// Export a single table
if (isset($_GET['single_table'])) {
$GLOBALS['single_table'] = $_GET['single_table'];
}
This is caused by a bug in version 4.8.4 of phpmyadmin. ppmyadmin team are working on it in this github issue.
There seems to a workaround available (I did not test it myself) : if I select the db, then checkbox the table(s), exporting under "with selected" I get the SQL option.
I am using xampp in ubuntu locally and I don't have /usr/local/psa/admin/htdocs/domains/databases/phpMyAdmin/libraries/classes/Display/Export.php file. SO I searched about this file and I found it here: /opt/lampp/phpmyadmin/libraries/classes/Display/Export.php After editing this file from the
// Export a single table
if (isset($_GET['single_table'])) {
$GLOBALS['single_table'] = $_GET['single_table'];
}
(as the first answer) resolved my problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With