【发布时间】:2016-07-11 15:17:27
【问题描述】:
我正在尝试使用 phpMyadmin 替换 wordpress 帖子内容中的一些句子 这是我的更新查询
UPDATE `wp_posts` SET `post_content` = REPLACE (`post_content`, 'Example Routes:', 'Routes:') WHERE `post_content` LIKE '%Example Routes:%';
但它显示“0 行受影响”。
我已经运行了一个具有相同条件的选择查询,以确保有结果并且我有很多结果 这是选择查询
SELECT * FROM `wp_posts` WHERE `post_content` LIKE '%Example Routes:%';
请注意,这两个查询条件与我更新的条件相同,我的条件是“LIKE '%Example Routes:%'”,更新是“REPLACE (post_content, 'Example Routes:', 'Routes: ')"。
知道为什么更新会影响到我 0 行吗?
【问题讨论】:
标签: php mysql wordpress phpmyadmin