Oracle Timer Call Stored procedure

Source: Internet
Author: User

1. Create a table

2. Create a stored procedure

Values

3. Create a timer job and specify it to be executed once a minute

Declare numberbegin'job_proc;' TRUNC (sysdate, 'mi') + 1/(24*60)'end      

4. Test View Table Data

5. Stop Timer

Right-click Edit to open, and then select the Broken check box, apply on it

In addition, it is automatically run after creation, query the job table to view the job information created

Select Job,broken,what,interval,t. from user_jobs t;  /**/

Add:

/* Description interval parameter value 12 O'Clock "TRUNC (sysdate + 1) Daily 8:30 A.M." TRUNC (sysdate + 1) + (8*60+30)/(24*60) "Every Tuesday noon 12 o'clock" next_ Day (TRUNC (sysdate), ' ' Tuesday ') + 12/24 "Midnight of the first day of each month 12 o'clock ' TRUNC (Last_day (sysdate) + 1) ' The last night of each quarter 11 o'clock ' TRUNC (ADD _months (Sysdate + 2/24, 3), "' Q ') -1/24 ' every Saturday and Sunday 6:10 A.M. ' TRUNC (LEAST (Next_day (sysdate," ' SATURDAY "), Next_day (SYSDA TE, "SUNDAY"))) + (6X60+10)/(24x60) '* * * 

Complete.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.