-
Dbms_job
HI all,
If I have the following job to be scheduled to run, can I add another DBMS_UTILITY to analyze for the second schema let say TEST2 ???
var j number
begin
dbms_job.submit
(
:j,
'SYS.DBMS_UTILITY.ANALYZE_SCHEMA(''TEST1'',''COMPUTE'');',
SYSDATE,
'NEXT_DAY(trunc(sysdate),''SATURDAY'')+1/12'
);
COMMIT;
end;
Thanks
-
var j number
begin
dbms_job.submit
(
:j,
'begin
SYS.DBMS_UTILITY.ANALYZE_SCHEMA(''TEST1'',''COMPUTE'');
SYS.DBMS_UTILITY.ANALYZE_SCHEMA(''TEST2'',''COMPUTE'');
end;',
SYSDATE,
'NEXT_DAY(trunc(sysdate),''SATURDAY'')+1/12'
);
COMMIT;
end;
... or just submit two jobs, of course.
By the way you should be using DBMS_STATS, not DBMS_UTILITY
-
Slimdave,
can you show me how to use Dbms_stats???
Thanks
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|