I. Overview of scheduling
Here I see an overview of scheduling that feels better than mine, but is limited to the overview section, other parts I think I speak better than him, so the following things happen:
Gorgeous reprint of *************************************************************************
in oracle, the Task Scheduler refers to an executing program that is periodically executed at a specific time. oracle the Task Scheduler called job. And a basic job consists of two aspects program and schedule. wherein program refers to the periodic execution of the executable program, which may include pl\sql anonymous blocks, stored procedures, functions, packages and operating system executables and external programs and so on. schedule refers to the period of dispatch program execution. The cycle can be scheduled either on a specific time basis or on an event basis. Thus job can be divided into two broad categories, time-based job and event-based job. Before the oracle 10g, the dbms_job package was used to complete the task scheduling work. After oracle 10g, oracle launched a more powerful dbms_schedule to complete the task scheduling work, Mainly because dbms_schedule can be based on event scheduling and dbms_job can not be based on event scheduling (the author's opinion, to be verified)!
Gorgeous reprint of *************************************************************************
Second, the role of scheduling
function, I can use the first picture to describe. If you describe it in a word, it is: simplify management tasks.
Three, the composition of the Dispatch
The dispatch contains 3 parts, in a word to describe that is: program + scheduling + job = scheduling
If you use a picture to describe it, that is:
Iv. creating a scheduling of opportunity time
1, I prefer to talk about programs, scheduling and jobs are created separately, when used to organize their associations in a piece to form a schedule, and do not like to create a job, inside splinters contains a lot of content.
2, this time I use the EM Enterprise Manager to create will be relatively simple, because the graphical interface is more and more convenient, and the inside of the show SQL is our memory of the SQL command is a great artifact of those who do not love. But there are some commands to keep in mind, otherwise we are not professional.
Create a test table: Job_test
Conn hr/hrcreate table job_test (sdate date);
3, look at the picture, according to the order we first create a program: The program is our entire schedule to do things are put here.
The source is what we want to do with this dispatch to do the action to write in here. All we have to do this time is insert a record into the Job_test table every second.
4. Create a scheduling schedule. Schedule types for scheduling schedules are: Standard and event type. This time I choose the standard scheduling plan.
5. Create a job, and then organize the program and schedule management together to form a schedule.
Look at the bottom, here we use the program we just created:
Use predefined scheduling schedules:
At this point, just click OK to get the job done.
6. Start the scheduling process:
To see if the job is working correctly:
As you can see, time-based scheduling is working correctly.
V. Create event-based scheduling
Here the content is more, the picture is more, so separate come, next to see: "Oracle scheduling based on event scheduling (ii)" Weber produced "
Time-based scheduling of Oracle scheduling (i) "Weber production"