Oracle DBMS_SCHED_MAIN_EXPORT
Version 21c

General Information
Library Note Morgan's Library Page Header
Which has the higher priority in your organization: Deploying a new database or securing the ones you already have? Looking for a website, and resources, dedicated solely to securing Oracle databases? Check out DBSecWorx.
Purpose Scheduler Export Main Program
AUTHID DEFINER
Dependencies
ALL_SCHEDULER_WINDOWS DBMS_SCHED_EXPORT_CALLOUTS SCHEDULER$_CONSTRAINTS
ALL_TABLES DBMS_SCHED_FILE_WATCHER_EXPORT SCHEDULER$_CREDENTIAL
DBA_SCHEDULER_FILE_WATCHERS DBMS_SCHED_JOB_EXPORT SCHEDULER$_GLOBAL_ATTRIBUTE
DBA_SCHEDULER_JOBS DBMS_SCHED_PROGRAM_EXPORT SCHEDULER$_JOB
DBA_SCHEDULER_PROGRAMS DBMS_SCHED_SCHEDULE_EXPORT SCHEDULER$_JOB_ARGUMENT
DBMS_ASSERT DBMS_SCHED_WINDOW_EXPORT SCHEDULER$_LIGHTWEIGHT_JOB
DBMS_DATAPUMP DBMS_SCHED_WINGRP_EXPORT SCHEDULER$_LWJOB_OBJ
DBMS_ISCHED DBMS_STANDARD SCHEDULER$_NOTIFICATION
DBMS_LOB DBMS_ZHELP SCHEDULER$_PROGRAM
DBMS_PRIV_CAPTURE KU$_JOBDESC SCHEDULER$_RESOURCES
DBMS_SCHEDULER KU$_STATUS SCHEDULER$_SCHEDULE
DBMS_SCHED_ARGUMENT_IMPORT NOEXP$ SCHEDULER$_STEP
DBMS_SCHED_ATTRIBUTE_EXPORT OBJ$ SCHEDULER$_WINDOW
DBMS_SCHED_CHAIN_EXPORT PLITBLM SCHEDULER$_WINDOW_GROUP
DBMS_SCHED_CLASS_EXPORT SCHEDULER$_CHAIN SCHEDULER$_WINGRP_MEMBER
DBMS_SCHED_CONSTRAINT_EXPORT SCHEDULER$_CLASS USER$
DBMS_SCHED_CREDENTIAL_EXPORT    
Documented No
First Available Not known
Security Model Owned by SYS with no privileges granted
Source {ORACLE_HOME}/rdbms/admin/prvthesh.plb
{ORACLE_HOME}/rdbms/admin/prvtesch.plb
Subprograms
 
EXPORT_CHAIN
Undocumented dbms_sched_main_export.export_chain(objid IN NUMBER);
TBD
 
EXPORT_CLASS
Undocumented dbms_sched_main_export.export_class(objid IN NUMBER);
TBD
 
EXPORT_CONSTRAINT
Undocumented dbms_sched_main_export.export_constraint(objid IN NUMBER);
TBD
 
EXPORT_CREDENTIAL
Undocumented dbms_sched_main_export.export_credential(
objid   IN NUMBER,
version IN NUMBER);
TBD
 
EXPORT_FILE_WATCHER
Undocumented dbms_sched_main_export.export_file_watcher(objid IN NUMBER);
TBD
 
EXPORT_GRANTS
Undocumented dbms_sched_main_export.export_grants(objid IN NUMBER);
TBD
 
EXPORT_JOB
Undocumented dbms_sched_main_export.export_job(
objid   IN NUMBER,
version IN NUMBER);
TBD
 
EXPORT_PROGRAM
Undocumented dbms_sched_main_export.export_program(
objid   IN NUMBER,
version IN NUMBER);
TBD
 
EXPORT_RESOURCE
Undocumented dbms_sched_main_export.export_resource(objid IN NUMBER);
TBD
 
EXPORT_RESOURCE_CONSTRAINT
Undocumented dbms_sched_main_export.export_resource_constraint(objid IN NUMBER);
TBD
 
EXPORT_SCHEDULE
Undocumented dbms_sched_main_export.export_schedule(objid IN NUMBER);
TBD
 
EXPORT_SCHEDULER_ATTRIBUTE
Undocumented dbms_sched_main_export.export_scheduler_attribute(
objid   IN NUMBER,
version IN NUMBER);
TBD
 
EXPORT_SYSTEM_WINDOW
Undocumented dbms_sched_main_export.export_system_window(
win_name       IN VARCHAR2,
res_plan       IN VARCHAR2,
duration       IN VARCHAR2,
schedule       IN VARCHAR2,
schedule_name  IN VARCHAR2,
schedule_owner IN VARCHAR2,
start_date     IN VARCHAR2,
end_date       IN VARCHAR2,
priority       IN VARCHAR2,
comments       IN VARCHAR2,
inline_sched   IN BINARY_INTEGER,
enabled        IN BINARY_INTEGER);
TBD
 
EXPORT_WINDOW
Undocumented dbms_sched_main_export.export_window(objid IN NUMBER);
SELECT o.obj#, o.name WIN_NAME
FROM obj$ o, scheduler$_window sw
WHERE o.obj# = sw.obj#;

 OBJ#   WIN_NAME
----- -----------------
19737 MONDAY_WINDOW
19738 TUESDAY_WINDOW
19739 WEDNESDAY_WINDOW
19740 THURSDAY_WINDOW
19741 FRIDAY_WINDOW
19742 SATURDAY_WINDOW
19743 SUNDAY_WINDOW
19761 WEEKNIGHT_WINDOW
19762 WEEKEND_WINDOW


exec dbms_sched_main_export.export_window(19743);

PL/SQL procedure successfully completed.
 
EXPORT_WINGRP
Undocumented dbms_sched_main_export.export_wingrp(objid IN NUMBER);
SELECT o.obj#, o.name WIN_GRP
FROM obj$ o, scheduler$_window_group swg
WHERE o.obj# = swg.obj#
AND bitand(swg.flags, 8+16) = 0;

 OBJ# WIN_GRP
----- --------------------------
19744 MAINTENANCE_WINDOW_GROUP
19748 ORA$AT_WGRP_OS
19752 ORA$AT_WGRP_SA
19756 ORA$AT_WGRP_SQ


exec dbms_sched_main_export.export_wingrp(19744);

PL/SQL procedure successfully completed.
 
GET_OBJECT_OWNER
Returns the schema owner of the identified object dbms_sched_main_export.get_object_owner(obj_id IN NUMBER) RETURN VARCHAR2;
SELECT dbms_sched_main_export.get_object_owner(42)
FROM dual;

DBMS_SCHED_MAIN_EXPORT.GET_OBJECT_OWNER(42)
--------------------------------------------
SYS
 
I_INSTANCE_CALLOUT_IMP
Undocumented dbms_sched_main_export.i_instance_callout_imp(
obj_name   IN  VARCHAR2,
obj_schema IN  VARCHAR2,
obj_type   IN  NUMBER,
prepost    IN  BINARY_INTEGER,
alt_name   OUT VARCHAR2);
TBD
 
I_SCHEMA_CALLOUT
Undocumented dbms_sched_main_export.i_schema_callout(
schema  IN VARCHAR2,
prepost IN BINARY_INTEGER,
version IN NUMBER);
TBD
 
I_SCHEMA_INFO_EXP
Undocumented dbms_sched_main_export.i_schema_info_exp(
schema  IN VARCHAR2,
prepost IN BINARY_INTEGER,
version IN NUMBER);
TBD
 
I_SYSTEM_CALLOUT_IMP
Undocumented dbms_sched_main_export.i_system_callout_imp(prepost IN BINARY_INTEGER);
TBD
 
NEXT_PIECE
Undocumented dbms_sched_main_export.next_piece(more_left IN OUT BOOLEAN) RETURN VARCHAR2;
TBD
 
TS_TO_CHAR
Returns a syntactically valid, fully formatted, TO_TIMESTAMP_TZ statement dbms_sched_main_export.ts_to_char(ts IN TIMESTAMP WITH TIME ZONE) RETURN VARCHAR2;
CREATE TABLE tint_test (
msg        VARCHAR2(25),
start_date TIMESTAMP WITH TIME ZONE,
end_date   TIMESTAMP WITH TIME ZONE,
duration_1 INTERVAL DAY(5) TO SECOND,
duration_2 INTERVAL YEAR TO MONTH);

INSERT INTO tint_test
(msg, start_date, end_date)
VALUES
('my plane ride',
timestamp'2021-11-08 17:02:32.212 US/Eastern',
timestamp'2021-11-08 19:10:12.235 US/Pacific');

COMMIT;

SELECT start_date
FROM tint_test;

START_DATE
---------------------------------------
08-NOV-21 05.02.32.212000 PM US/EASTERN

SELECT dbms_sched_main_export.ts_to_char(start_date)
FROM tint_test;

DBMS_SCHED_MAIN_EXPORT.TS_TO_CHAR(START_DATE)
------------------------------------------------------------------------------------------
TO_TIMESTAMP_TZ('08-NOV-2021 05.02.32.212000000 PM US/EASTERN','DD-MON-RRRR HH.MI.SSXFF AM TZR','NLS_DATE_LANGUAGE=english')

Related Topics
Built-in Functions
Built-in Packages
Database Security
DBMS_SCHEDULER
DBMS_SCHED_ATTRIBUTE_EXPORT
DBMS_SCHED_CHAIN_EXPORT
DBMS_SCHED_CLASS_EXPORT
DBMS_SCHED_CONSTRAINT_EXPORT
DBMS_SCHED_CREDENTIAL_EXPORT
DBMS_SCHED_EXPORT_CALLOUTS
DBMS_SCHED_FILE_WATCHER_EXPORT
What's New In 19c
What's New In 20c-21c

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2021 Daniel A. Morgan All Rights Reserved
  DBSecWorx