题目:
15. You work as a database administrator at Certkiller .com. In your production
database there is a job, CALC_STAT, which has been scheduled to run every Friday at 5.00 p.m.
CALC_STAT updates the optimizer statistics for the objects owned by the APPS schema. You want the task
to be generic, there by allowing users to modify the attributes of the task at run time without
affecting the original task.Which component of Oracle Scheduler must you define to achieve this?
A. Window
B. Program
C. Job class
D. Window group
Answer: B
题目翻译:作为Certkiller.com的数据管理员,在生产数据库上有一个job名为CALC_STATE,已经计划每周五下午5点运行。它的功能是为apps schema拥有的objects更新optimizer statistics。你希望这个工作是generic的,因此允许用户可以在运行时间修改工作的attributes参数,而不影响原先的task。哪个oracle scheduler模块组件可以用来完成这项工作?
答案解释:
Programs
Programs provide a layer of abstraction between the job and the action it will perform.They are created with the DBMS_SCHEDULER.CREATE_PROGRAM procedure:
PROCEDURE CREATE_PROGRAM
Argument Name Type In/Out Default?
------------------------------------------- ------------------------------ ------ --------
PROGRAM_ NAME VARCHAR2 IN
PROGRAM_TYPE VARCHAR2 IN
PROGRAM_ACTION VARCHAR2 IN
NUMBER_OF_ARGUMENTS BINARY_INTEGER IN DEFAULT
ENABLED BOOLEAN IN DEFAULT
COMMENTS VARCHAR2 IN DEFAULT
By pulling the “what” of a job out of the job definition itself and defining it in a program, it becomes possible to reference the same program in different jobs, and
thus to associate it with different schedules and job classes, without having to define it many times. Note that (as for a job) a program must be ENABLED before it can be used.