如何写sql

happyfly2003 2003-12-26 12:59:14
表a,表b
a,b有相同的记录!比如都有字段column1,column2.我想根据column1做条件。以b更新a中的column2

如何写sql
...全文
98 4 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
hglhyy 2003-12-26
  • 打赏
  • 举报
回复
update a set a.column2=b.column2 from a,b where a.column1=b.column1
solidpanther 2003-12-26
  • 打赏
  • 举报
回复
update a set a.column2=b.column2 from a,b where a.column1=b.column1
bobohuang 2003-12-26
  • 打赏
  • 举报
回复
update a
set a.column2=b.column2
from a,b where a.column1=....
饮水需思源 2003-12-26
  • 打赏
  • 举报
回复
update a set a.column2=b.column2
from a,b
where a.column1=b.column1

34,838

社区成员

发帖
与我相关
我的任务
社区描述
MS-SQL Server相关内容讨论专区
社区管理员
  • 基础类社区
  • 二月十六
  • 卖水果的net
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧