- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在迁移 wordpress 网站。使用 phpmyadmin 从旧服务器导入 SQLdump 返回语法错误。
导出自:
phpMyAdmin SQL Dump
version 4.2.8.1
Serverversie: 5.5.37
PHP-versie: 5.3.29
导入:
phpMyAdmin
version 4.5.0.2
Serverversie: 5.5.44-MariaDB
PHP-versie: 5.5.30
语法错误:
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'about', 'about', '{"title":"about","alias":"about","shortcode":"[rev_slider abou' at line 2
SQL 查询。注意,前 13 个表导入没有问题
INSERT INTO `d8up675e4c_revslider_sliders` (`id`, `title`, `alias`, `params`) VALUES
(2, 'Full-Screen-1', 'Full-Screen-1', '{"title":"Full-Screen-1","alias":"Full-Screen-1","shortcode":"[rev_slider Full-Screen-1]","source_type":"gallery","post_types":"post","post_category":"category_41","post_sortby":"ID","posts_sort_direction":"DESC","max_slider_posts":"30","excerpt_limit":"55","slider_template_id":"","posts_list":"","slider_type":"fullscreen","fullscreen_offset_container":"","fullscreen_min_height":"","full_screen_align_force":"off","auto_height":"on","force_full_width":"on","responsitive_w1":"940","responsitive_sw1":"770","responsitive_w2":"780","responsitive_sw2":"500","responsitive_w3":"510","responsitive_sw3":"310","responsitive_w4":"0","responsitive_sw4":"0","responsitive_w5":"0","responsitive_sw5":"0","responsitive_w6":"0","responsitive_sw6":"0","width":"1160","height":"1000","delay":"5000","shuffle":"off","lazy_load":"off","use_wpml":"off","stop_slider":"off","stop_after_loops":0,"stop_at_slide":2,"load_googlefont":"false","google_font":["<link href=\\\\''http:\\/\\/fonts.googleapis.com\\/css?family=PT+Sans+Narrow:400,700\\\\'' rel=\\\\''stylesheet\\\\'' type=\\\\''text\\/css\\\\''>"],"position":"center","margin_top":0,"margin_bottom":0,"margin_left":0,"margin_right":0,"shadow_type":"0","show_timerbar":"hide","padding":0,"background_color":"#000000","background_dotted_overlay":"none","show_background_image":"false","background_image":"http:\\/\\/domain.com\\/wp-content\\/","bg_fit":"normal","bg_repeat":"repeat","bg_position":"center top","touchenabled":"on","stop_on_hover":"off","navigaion_type":"bullet","navigation_arrows":"solo","navigation_style":"round","navigaion_always_on":"false","hide_thumbs":200,"navigaion_align_hor":"center","navigaion_align_vert":"bottom","navigaion_offset_hor":"0","navigaion_offset_vert":20,"leftarrow_align_hor":"left","leftarrow_align_vert":"center","leftarrow_offset_hor":20,"leftarrow_offset_vert":0,"rightarrow_align_hor":"right","rightarrow_align_vert":"center","rightarrow_offset_hor":20,"rightarrow_offset_vert":0,"thumb_width":100,"thumb_height":50,"thumb_amount":5,"hide_slider_under":0,"hide_defined_layers_under":0,"hide_all_layers_under":0,"hide_thumbs_under_resolution":0,"start_with_slide":"1","first_transition_type":"fade","first_transition_duration":300,"first_transition_slot_amount":7,"reset_transitions":"","reset_transition_duration":0,"0":"Execute settings on all slides","jquery_noconflict":"on","js_to_body":"false","output_type":"none","template":"false"}'),
测试了以下内容。
测试 1。尝试了其他数据库转储(来自旧服务器),但它们也返回语法错误。
测试 2。命令行 mysqldump
旧服务器,命令行 mysql 导入新服务器。这工作没有错误。但是当我尝试使用 phpmyadmin(新服务器)'export/clear db/import' 时,我得到了同样的错误?
测试 3。清除 params
值:
INSERT INTO `d8up675e4c_revslider_sliders` (`id`, `title`, `alias`, `params`) VALUES
(2, 'Full-Screen-1', 'Full-Screen-1', '{}'),
(3, 'about', 'about', '{}'),
(4, 'our-story', 'our-story', '{}'),
(5, 'Screens', 'screens', '{}');
现在所有 CREATE TABLE
和 INSERT INTO
都已完成且没有错误。但是我收到以下语法错误:
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'ALTER TABLE `d8up675e4c_commentmeta`
ADD PRIMARY KEY (`meta_id`),
ADD KEY `c' at line 133
SQL查询
INSERT INTO `d8up675e4c_wpsl_stores` (`wpsl_id`, `store`, `address`, `address2`, `city`, `state`, `zip`, `country`, `country_iso`, `lat`, `lng`, `description`, `phone`, `fax`, `url`, `email`, `hours`, `thumb_id`, `active`) VALUES
(1, 'Shoes shop | Office', 'street 181', '', 'demo city', 'Noord-Brabant', '1111 TM', 'Nederland', 'NL', 51.675339, 4.995821, '', '', '', 'www.domain.com', 'info@domain.com', '', 3065, 1),
(5, 'April Fashion & Shoes', 'street 1', '', 'VALKENS[...]
错误 ALTER TABLE
ALTER TABLE `d8up675e4c_commentmeta`
ADD PRIMARY KEY (`meta_id`),
ADD KEY `comment_id` (`comment_id`),
ADD KEY `meta_key` (`meta_key`(191));
要特别清楚,这些是我使用 phpmyadmin(在新服务器上)“导出/清除数据库/导入”时的语法错误....我使用命令行从旧服务器导入 SQL 文件。
在旧服务器上尝试了许多不同的 phpmyadmin 导出设置,但每次我在新服务器上都遇到相同的错误。
当我导出/导入在该服务器上创建的网站时,它可以正常工作。这与旧服务器相同..
不知道要测试什么,我找不到解决方案..
显然这与不同的 MySQl 或 phpmyadmin 版本有关。如何解决?
问候,比约恩
最佳答案
发现问题...
经过几个小时的测试后,我发现 MariaDB 不接受以下值:
\\''
我只在少数数据库转储中发现了这一点,每个转储中大约出现 10 次,主要在 url 的..旧服务器上的一些插件已经使用 \\''
保存了它们的设置。
导入失败并出现语法错误的示例
(618, 'wpdm_login_msg', '<a href=\\''http://domain.com/wp-login.php\\'' >Please login to download</a>', 'yes'),
注意 url 中的 \\''
,将它们替换为 "可修复所有导入问题。
关于mysql - 网站迁移,phpmyadmin 导出/导入语法错误#1064,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33742398/
在 phpMyAdmin 的设置过程中,创建了一个 phpMyAdmin 用户,当我查看 phpMyAdmin 数据库权限时,我可以看到该用户。哪个 PHP 文件存储了该用户的密码? 最佳答案 保罗,
如何删除 phpMyAdmin 中的框架? 最佳答案 打开/usr/share/phpmyadmin/index.php(它在我的 Ubuntu 机器上)。不要忘记使用 sudo 或成为 root。
我读过官方文档说 phpMyAdmin 应该安装在 Web 服务器的文档根目录中。 我想问一下我是否必须为我拥有的每个 DocumentRoot 放置一个 phpMyAdmin,或者是否有一个很好的解
在遵循 youtube 上的 2019 教程后,无法在 virtualbox 上滚动的 kali linux 上安装 phpmyadmin, 尝试过 sudo apt-get install phpm
请帮忙,我总是在经历所有这些事情时遇到麻烦。当我只需要 phpmyadmin 有一个登录表单时,我就可以输入密码和用户名。 我不需要本文档中包含的所有内容。是否有针对初学者的教程,介绍如何在 phpm
标题几乎总结了我的问题。 我只想了解如何禁用远程登录到我的 phpmyadmin。 我宁愿只能从本地主机登录到 phpmyadmin。 最佳答案 编辑 /etc/phpmyadmin/apache.c
已关闭。这个问题是 not reproducible or was caused by typos 。目前不接受答案。 这个问题是由拼写错误或无法再重现的问题引起的。虽然类似的问题可能是 on-top
我创建了具有两列(id、name)的数据库(产品)表项目,并且我向该列添加了值,然后显示此错误 Warning in .\libraries\DisplayResults.php#869 A non
我想将 SELECT 查询的结果导出为有效的 SQL INSERTS,并将其导入到另一个数据库中(某些记录被意外删除)。通常我会使用 PHPMyAdmin 的导出功能,但 PHPMyAdmin 在其中
当我尝试从 phpMyAdmin 导出数据库时出现错误。 请引用下面的截图。 我不知道这个问题是怎么发生的。 最佳答案 我遇到了同样的问题,我通过增加 php.ini 中 'max_input_var
无法访问 phpMyAdmin。我的 wampserver 版本是 2.2,使用 Windows 7。 localhost/phpmyadmin/ 当我打开它。 Internet Explorer 打
在我的工作中,我有 phpmyadmin 要使用的 SQL 数据库(本地和服务器上) 烦人的问题是,当我修改本地数据库结构(列、关系、新表)时,我不得不在服务器数据库上再次重做修改,因为当我备份本地数
我不喜欢 phpMyAdmin 中新的 AJAX 风格的导航树,我想将其更改为旧的。是否有一些我可以更改的配置指令? 旧版本:3.3.7 新版本:4.0.4 两者中的原始主题。 最佳答案 没有配置指令
我正在尝试更改 phpmyadmin 中的日期格式。我无法更改格式 我想将格式更改为 dd-mmm-yyyy。如何更改日期格式。请帮我解决它.. 最佳答案 您可以使用 phpMyAdmin 的 bro
我想在 PhpMyAdmin 中为包含此文本的所有字段更改文本“pelecard”。表名是 sales_flat_order_payment。我怎么能做到这一点? 谢谢你 最佳答案 SQL 是什么?
在远程 ubuntu 18 服务器上,当从其中一个表中打开 phpmyadmin 中的数据时,它会显示警告和弹出窗口(如 https://imgur.com/a/b5HGGV0 ),这是非常缺乏的..
默认情况下,phpMyAdmin 中的“主题”选项仅影响主题设置更改的浏览器的主题(可能存储在 cookie 中?)。如何将特定主题设置为所有用户的默认主题? 最佳答案 可以从 phpMyAdmin
我的表有全文列。如何设置列的默认宽度?我知道它在 index.php 页面顶部有完整/部分文本按钮...如何永久设置该值? 谢谢! 最佳答案 有一个名为 LimitChars 的配置值:http://
我是 mysql 的新手,所以我正在使用 phpmyadmin 在数据库中创建表。我有枚举类型的字段制造商,可能的值为“manufacturer1”,“manufacturer2”,... 我选择了
有谁知道是否或如何增加phpMyAdmin 中的导入大小限制?目前我的服务器限制为 50MB。 请注意,这与 php.ini 中的 upload_max_filesize 不同。该值设置为 2MB。
我是一名优秀的程序员,十分优秀!