您好我仍在为以下代码而苦苦挣扎
INSERT INTO m4zbv_mt_cfvalues (cf_id, link_id,value)
SELECT 87,link_id,1
FROM m4zbv_mt_links WHERE Upper(`link_name`) like'%#VMWARE APPLIANCE DEFAULT PASSWORDS%'
WHERE NOT EXISTS(select cf_id, link_id from m4zbv_mt_cfvalues where cf_id=87 and link_id=m4zbv_mt_links.link_id)
这部分工作正常:
INSERT INTO m4zbv_mt_cfvalues (cf_id, link_id,value)
SELECT 87,link_id,1
FROM m4zbv_mt_links WHERE Upper(`link_name`) like'%#VMWARE APPLIANCE DEFAULT PASSWORDS%'
我不确定如何m4zbv_mt_links.link_id
从第一个选择中传递值以及如何集成WHERE NOT EXISTS
谢谢你的帮助