我在下面使用但是收到错误,这段代码有什么问题:
declare
begin
for i in 1..20
loop
execute immediate 'update table IMP_BACKUP set name='XYZ' where status='INVALID'';
end loop;
end;
/
答案 0 :(得分:0)
将变量i声明为
declare
i number(2);
begin
for i in 1..20 loop
execute immediate 'update table IMP_BACKUP set name=''XYZ'' where status=''INVALID''';
end loop;
end;
/