导航

修改表内部分字段根据查询而来 update select from

Posted on 2019-04-03 16:33  Suspecter  阅读(544)  评论(0编辑  收藏  举报

UPDATE event_layout_config a
INNER JOIN (
SELECT
field_name,
classify,
property,
field_struct
FROM
event_layout_config
WHERE
iam_organization_id = 1
AND page_name = 2
AND project_id = 5
AND category_code = 'INCIDENT'
) c ON a.field_name = c.field_name
SET a.classify = c.classify,
a.property = c.property,
a.field_struct = c.field_struct
where a.iam_organization_id=0 and page_name=2