DBMS_JOB.SUBMIT 建立job定時排程
SUBMIT Procedure
This procedure submits a new job. It chooses the job from the sequence sys.jobseq.
Syntax
DBMS_JOB.SUBMIT ( job OUT BINARY_INTEGER, what IN VARCHAR2, next_date IN DATE DEFAULT sysdate, interval IN VARCHAR2 DEFAULT 'null', no_parse IN BOOLEAN DEFAULT FALSE, instance IN BINARY_INTEGER DEFAULT any_instance, force IN BOOLEAN DEFAULT FALSE);
Parameters
Table 78-9 SUBMIT Procedure Parameters
Parameter | Description |
---|---|
job |
Number of the job being run. |
what |
PL/SQL procedure to run. |
next_date |
Next date when the job will be run. |
interval |
Date function that calculates the next time to run the job. The default is NULL. This must evaluate to a either a future point in time or NULL. |
no_parse |
A flag. The default is FALSE. If this is set to FALSE, then Oracle parses the procedure associated with the job. If this is set to TRUE, then Oracle parses the procedure associated with the job the first time that the job is run. For example, if you want to submit a job before you have created the tables associated with the job, then set this to TRUE. |
instance |
When a job is submitted, specifies which instance can run the job. |
force |
If this is TRUE, then any positive integer is acceptable as the job instance. If this is FALSE (the default), then the specified instance must be running; otherwise the routine raises an exception. |
Usage Notes
-
You must issue a COMMIT statement immediately after the statement.
-
The parameters instance and force are added for job queue affinity. Job queue affinity gives users the ability to indicate whether a particular instance or any instance can run a submitted job.
Example
This submits a new job to the job queue. The job calls the procedure DBMS_DDL.ANALYZE_OBJECT to generate optimizer statistics for the table DQUON.ACCOUNTS. The statistics are based on a sample of half the rows of the ACCOUNTS table. The job is run every 24 hours:
VARIABLE jobno number; BEGIN DBMS_JOB.SUBMIT(:jobno, 'dbms_ddl.analyze_object(''TABLE'', ''DQUON'', ''ACCOUNTS'', ''ESTIMATE'', NULL, 50);' SYSDATE, 'SYSDATE + 1'); COMMIT; END; / Statement processed. print jobno JOBNO ---------- 14144
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29477587/viewspace-1154618/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Linux 定時任務排程Linux
- Spring排程定時任務的方式Spring
- Android 中的定時任務排程Android
- xxl-job,任務排程中心快速上手
- 使用Java實現定時任務排程Java
- 3 分鐘建立 Serverless Job 定時獲取新聞熱搜!Server
- 3 分鐘建立 Serverless Job 定時獲取新聞熱搜Server
- micro-job分散式任務排程框架更新分散式框架
- 分散式任務排程平臺XXL-JOB分散式
- 深入 Java Timer 定時排程器實現原理Java
- 定時排程系列之Quartz.Net詳解quartz
- Apache DolphinScheduler 限制秒級別的定時排程Apache
- 用海豚排程器定時排程從Kafka到HDFS的kettle任務指令碼Kafka指令碼
- Elastic-job實戰(分散式作業排程框架)AST分散式框架
- laravel框架任務排程(定時執行任務)Laravel框架
- 基於Azkaban的任務定時排程實踐
- Mvc專案利用Quartz實現定時排程DemoMVCquartz
- Oracle資料庫定時器JobOracle資料庫定時器
- 深入 Java Timer 定時任務排程器實現原理Java
- 分散式任務排程平臺XXL-JOB快速搭建教程分散式
- Oracle無法自動排程DBMS_JOB&DBMS_SCHEDULER案例分析Oracle
- 程序排程的時機
- 詳解 MySQL 用事件排程器 Event Scheduler 建立定時任務MySql事件
- 詳解MySQL用事件排程器Event Scheduler建立定時任務MySql事件
- DolphinScheduler心臟:Quartz的定時任務排程框架深度解析quartz框架
- XXL-JOB定時任務框架(Oracle定製版)框架Oracle
- Flink排程之排程器、排程策略、排程模式模式
- 軟中斷排程時機
- Oracle 定時任務job實際應用Oracle
- 使用oracle job定時傳送email郵件OracleAI
- [原始碼分析] 定時任務排程框架 Quartz 之 故障切換原始碼框架quartz
- 作業排程中介軟體 Elastic-Job-Cloud 原始碼分析 —— 高可用ASTCloud原始碼
- 2.2.5排程演算法:時間片輪轉、優先順序排程、多級反饋排程演算法
- 3分鐘帶你掌握Spring Boot中的定時排程服務Spring Boot
- 使用RestCloud ETL Shell元件實現定時排程DataX離線任務RESTCloud元件
- Linux Shell指令碼時間排程Linux指令碼
- Go runtime 排程器精講(三):main goroutine 建立GoAI
- dcat-admin版的定時任務管理排程擴充套件釋出套件
- 一個輕量級的分散式定時任務排程平臺-Cloudtask分散式Cloud