请使用precompile assets
子查询
UPDATE-SET
查询帮助我
我有表A和B,每个表中有DATED和ID列 我需要根据某些ID在表A中设置DATED of row with row Dating - 就像这样(简化示例):
SELECT
UPDATE A SET DATED = (SELECT DATED FROM B WHERE ID = yyy) WHERE ID = xxx;
和xxx
是常量(数字)
Oracle返回错误 - 它无法理解第二个WHERE ..
答案 0 :(得分:0)
UPDATE A SET a.DATED = (SELECT b.DATED FROM B WHERE b.ID = yyy) WHERE a.ID = xxx;
使用别名