update problem
我想更新我的表
FunctionLog
caseid functionid systemtype eventid
1 1 23
2 1 23
3 1 12
4 1 4
SystemEvent
eventid systemtype
4 1
12 3
23 4
如何用UPDATE语句来更新Functionlog里的systemtype里的值
UPDATE CVCT.dbo.FunctionLog SET systemtype =(Select distinct systemtype from FMCV.dbo.SystemEvent se where se.eventid in
(Select s.eventid from CVCT.dbo.FunctionLog s))
我的SQL语句不行, 得到的systemtype全是eventid23的值4
谁能帮我一下。