我在mysql中遇到问题。 这是来自wordpress博客,并尝试设置每个帖子al_ meta_key和meta_value的标题
INSERT `wordpress_postmeta` (`meta_id` ,`post_id` ,`meta_key` ,`meta_value`)
VALUES ( '',`ID` , _yoast_wpseo_focuskw, `wordpress_posts`.`post_title`)
(`wordpress_posts`.`ID` , _yoast_wpseo_focuskw, `ewordpress_posts`.`post_title`)
SELECT * FROM ewordpress_posts WHERE (`wordpress_posts`.`post_status` = 'future'))
答案 0 :(得分:0)
试试:
INSERT INTO `wordpress_postmeta` (`meta_id` ,`post_id` ,`meta_key` ,`meta_value`)
SELECT '',t1.`ID` , t2._yoast_wpseo_focuskw, t1.`post_title`
FROM ewordpress_posts t1, ekwh_wordpress_postmeta t2
WHERE `post_status` = 'future'
此假设_yoast_wpseo_focuskw
位于您的表ewordpress_posts