sql 语句:
update a set a.reference=cid from custom a inner join
(select b.id as cid,b.phone as phone from custom as b ) con a.reference=c.phone
本文深入解析了SQL语句中基于关联查询的实现方式,通过具体实例展示了如何使用INNER JOIN操作符连接两个表,并更新目标表中的引用字段。详细介绍了查询结构、执行过程以及实际应用中的注意事项。
sql 语句:
update a set a.reference=cid from custom a inner join
(select b.id as cid,b.phone as phone from custom as b ) c
被折叠的 条评论
为什么被折叠?