我在plsql里面创建了个Jobs,可是老是执行失败,请帮忙看看;失败四次了.
beginsys.dbms_job.submit(job=>:job,what=>'createorreplacetablezhenghongas(select*from...
begin
sys.dbms_job.submit(job => :job,
what => 'create or replace table zhenghong as (select * from TC_SFB_FILE);',
next_date => to_date('12-09-2012 21:51:39', 'dd-mm-yyyy hh24:mi:ss'),
interval => 'sysdate+1');
commit;
end; 展开
sys.dbms_job.submit(job => :job,
what => 'create or replace table zhenghong as (select * from TC_SFB_FILE);',
next_date => to_date('12-09-2012 21:51:39', 'dd-mm-yyyy hh24:mi:ss'),
interval => 'sysdate+1');
commit;
end; 展开
1个回答
展开全部
what是填你要做的事情,what值啊
'create or replace table zhenghong as (select * from TC_SFB_FILE);
这个才是what值
你把语句都全部写在那里面了
把这个建表的语句先写个过程再试试
Create Or Replace Procedure Pro123
Authid Current_User
Is
Begin
Execute Immediate (create table zhenghong as (select * from TC_SFB_FILE);
End;
然后what里面填过程名pro123
'create or replace table zhenghong as (select * from TC_SFB_FILE);
这个才是what值
你把语句都全部写在那里面了
把这个建表的语句先写个过程再试试
Create Or Replace Procedure Pro123
Authid Current_User
Is
Begin
Execute Immediate (create table zhenghong as (select * from TC_SFB_FILE);
End;
然后what里面填过程名pro123
追答
汗,你看下那里有问题调试一下啊,我没调试
Create Or Replace Procedure Pro123
Authid Current_User
Is
Begin
Execute Immediate ('create table zhenghong as select * from TC_SFB_FILE');
End;
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询