我正在从FOO和BAR表中进行选择。我想锁定正在返回的FOO记录,但我不想锁定BAR的记录。
cursor c_foobar is
select foo.*, bar.* from
foo, bar
where foo.id = bar.foo_id
for update of <what should I put here?>
看起来我需要指定单独的列,但我希望锁定整个foo记录。例如,我希望能够执行以下操作:
cursor c_foobar is
select foo.*, bar.* from
foo, bar
where foo.id = bar.foo_id
for update of foo
我需要在
for update of
部分列出 foo 表中的每一列才能锁定所有列吗?或者我可以任意选择 foo 表中的任何列,即使它们不是主键,也会锁定整个记录吗?
salary
”。 - Jeffrey Kemp