update a
set a.col1 = 1,
a.col2 = 'abc' + CAST(b.colID AS VARCHAR(3))
from #abc a
cross apply
(select top 1 x.col3, x.colID1
from #xyz x
where (x.col3 = a.col3 and
x.colID1 IN (0, 9, 8))) b
表abc 和 xyz 是临时表,这就是"#"的原因。 需要将上述脚本转换为甲骨文
下面的链接可以帮助你实现你想要的... https://oracle-base.com/articles/18c/private-temporary-tables-18c