本文主要是介绍关于过程CREATE_JOB_CLASS Procedure,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
文档地址:http://docs.oracle.com/cd/B19306_01/appdev.102/b14258/d_sched.htm#i1011092
CREATE_JOB_CLASS Procedure
This procedure creates a job class. Job classes are created inthe SYS
schema.
DBMS_SCHEDULER.CREATE_JOB_CLASS (job_class_name IN VARCHAR2,resource_consumer_group IN VARCHAR2 DEFAULT NULL,service IN VARCHAR2 DEFAULT NULL,logging_level IN PLS_INTEGERDEFAULT DBMS_SCHEDULER.LOGGING_RUNS,log_history IN PLS_INTEGER DEFAULT NULL,comments IN VARCHAR2 DEFAULT NULL);
Table 93-12 CREATE_JOB_CLASS ProcedureParameters
Parameter | Description |
---|---|
| The name of the class being created. A schema other than This attribute specifies the name of the job class and uniquelyidentifies the job class. The name has to be unique in the SQLnamespace. For example, a job class cannot have the same name as atable in a schema. |
| This attribute specifies the resource consumer group this classis associated with. A resource consumer group is a set ofsynchronous or asynchronous sessions that are grouped togetherbased on their processing needs. A job class has a many-to-onerelationship with a resource consumer group. The resource consumergroup that the job class associates with will determine theresources that will be allocated to the job class. If the resource consumer group that a job class is associatedwith is dropped, the job class will then be associated with thedefault resource consumer group. If no resource consumer group is specified, the job class isassociated with the default resource consumer group. If the specified resource consumer group does not exist whencreating the job class, an error occurs. If |
| This attribute specifies the database service that the jobs inthis class will have affinity to. In a RAC environment, this meansthat the jobs in this class will only run on those databaseinstances that are assigned to the specific service. If a service is specified, If no service is specified, the job class will belong to thedefault service, which means it will have no service affinity andany one of the database instances within the cluster might run thejob. If the service that a job class belongs to is dropped, the jobclass will then belong to the default service. If the specified service does not exist when creating the jobclass, then an error occurs. |
| This attribute specifies how much information is logged. Thethree possible options are:
|
| This enables you to control the amount of logging the Schedulerperforms. To prevent the job log and the window log from growingindiscriminately, the Scheduler has an attribute that specifies howmuch history (in days) to keep. Once a day, the Scheduler willautomatically purge all log entries from both the job log as wellas the window log that are older than the specified history. Thedefault is 30 days. You can change the default by using the
The range of valid values is 1 through 999. |
| This attribute is for an optional comment about the job class.By default, this attribute is |
For users to create jobs that belong to a job class, the jobowner must have EXECUTE
privileges on the job class.Therefore, after the job class has been created,EXECUTE
privileges must be granted on the job class sothat users create jobs belonging to that class. You can also grantthe EXECUTE
privilege to a role.
Creating a job class requires the MANAGE
SCHEDULER
system privilege.
这篇关于关于过程CREATE_JOB_CLASS Procedure的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!