脚本超时已通过,如果要完成导入,请重新提交相同的文件,导入将恢复

我在mysql中导入数据库时​​收到此错误,当我重新提交相同的文件时,我收到此错误

Error SQL query: -- -- Dumping data for table `adminnotification_inbox` -- INSERT INTO `adminnotification_inbox` (`notification_id`, `severity`, `date_added`, `title`, `description`, `url`, `is_read`, `is_remove`) VALUES (1, 4, '2008-07-25 05:24:17', 'Magento 1.1 Production Version Now Available', 'We are thrilled to announce the availability of the production release of Magento 1.1. Read more about the release in the Magento Blog.', 'http://www.magentocommerce.com/blog/comments/magento-11-is-here-1/', 0, 0), (2, 4, '2008-08-02 05:29:53', 'Updated iPhone Theme is now available', 'Updated iPhone theme for Magento 1.1 is now available on Magento Connect and for upgrade through your Magento Connect Manager.', 'http://www.magentocommerce.com/blog/comments/updated-iphone-theme-for-magento-11-is-now-available/', 0, 0), (3, 3, '2008-08-02 05:40:04', 'Magento version 1.1.2 is now available', 'Magento version 1.1.2 is now available for download and upgrade.', 'http://www.magentocommerce.com/blog/comments/mag[...] MySQL said: Documentation #1062 - Duplicate entry '1' for key 'PRIMARY' 

我现在应该怎么做。 我已经在互联网上使用了时间增加的解决方案但没有任何反应。 我该如何解决这个错误。

我的数据库大小只有3 MB。 我在ubuntu 12.04中使用xampp 1.8.3。

您可以使用LAMP(Linux Apache MySQL PHP)代替XAMPP。 使用LAMP您可能还会遇到此问题。

在我的情况下(使用Ubuntu 15.10),我使用php.ini文件配置/设置post_max_size,upload_max_filesize,max_execution_time,max_input_time,memory_limit,该文件位于/etc/php5/apache2/php.ini

但我仍然遇到了这个问题。 然后使用config.default.php文件解决了这个问题,你可以在这里找到如下这一行:

 $cfg['ExecTimeLimit'] = 300; 

成功

$cfg['ExecTimeLimit'] = 0;

注意:您可以通过终端(Ctrl + Alt + T)通过此命令locate config.default.php可能的路径是/usr/share/phpmyadmin/libraries/config.default.php

希望这可以帮助。 🙂

让它放下,然后在phpmyadmin config.inc.php中你可以将时间从300秒增加到无穷大

添加此行

 $cfg['ExecTimeLimit'] = 0; 

和:

 php> php.ini 

找:

 post_max_size = 8M upload_max_filesize = 2M max_execution_time = 30 max_input_time = 60 memory_limit = 8M 

改成:

 post_max_size = 750M upload_max_filesize = 750M max_execution_time = 300 max_input_time = 540 memory_limit = 1000M 

发生这种情况是因为列ID的现有值已经为1 ,您在其中将其定义为要插入的表中的PRIMARY KEY (主键的值是唯一值)。

尝试将列ID设置为AUTO_INCREMENT

我希望这可以解决你的问题,我注意到你修复了你的XAMPP安装问题,请关闭这个未解决的问题在ubuntu软件中心找不到Xampp

转到xampp / phpMyAdmin / libraries / config.default.php找到$cfg['ExecTimeLimit'] = 300; 第695行并替换$cfg['ExecTimeLimit'] = 0;