Oracle DBMS_RCVMAN
Version 12.1.0.1

General Information
Library Note Morgan's Library Page Footer
The Library is currently in the process of being upgraded from Oracle Database Version 11.2.0.3 to 12.1.0.1. Demos are being upgraded to reflect the new Container paradigm as well as EBR (Edition Based Redefinition) and may contain references to CDBs, PDBs, and other objects you may not be familiar with such as CDB_OBJECTS_AE: Welcome to 12c.
Purpose Recovery manager package used by RMAN
AUTHID CURRENT_USER
Constants (General)
Name Data Type Value Version Description
FALSE# NUMBER 0 8.1.5 Numeric representation of FALSE
TRUE# NUMBER 1 8.1.5 Numeric representation of TRUE
COPY NUMBER 1 8.1.6 any image copy of a file
FULL_DF_BACKUP NUMBER 2 8.1.6 datafile in a full backup set
INCREMENTAL_DF_BACKUP NUMBER 3 8.1.6 datafile in an incr backup set
BACKUP NUMBER 4 8.1.6 any file in a backup set (incl proxy)
OFFLINE_RANGE NUMBER 5 8.1.6 an offline range
CUMULATIVE NUMBER 6 8.1.6 cumulative incremental - for LIST only
PROXY NUMBER 7 8.1.6 any proxy copy of a file
NONPROXY NUMBER 9 8.1.6 any image, backup set other than proxy
Constants (Backupset Availability Mask: Deprecated as of 8.1.6)
Name Data Type Value
BSavailable BINARY_INTEGER 2**0
BSunavailable BINARY_INTEGER 2**1
BSdeleted BINARY_INTEGER 2**2
BSexpired BINARY_INTEGER 2**3
BSpartial_avail BINARY_INTEGER 2**4
Constants (Backupset Validation Record)
Name Data Type Value
bsRecCacheEnabled BOOLEAN TRUE
bsRecCacheLowLimit NUMBER 2048
bsRecCacheHighLimit NUMBER 32768
Constants (Backup Type)
Name Data Type Value
archivedlog_txt VARCHAR2(16) 'ARCHIVED LOG'
available_txt VARCHAR2(16) 'AVAILABLE'
backupset_txt VARCHAR2(16) 'BACKUP SET'
controlfile_txt VARCHAR2(16) 'CONTROLFILE'
copy_txt VARCHAR2(16) 'COPY'
datafile_txt VARCHAR2(16) 'DATAFILE'
deleted_txt VARCHAR2(16) 'DELETED'
expired_txt VARCHAR2(16) 'EXPIRED'
full_txt VARCHAR2(16) 'FULL'
incr_txt VARCHAR2(16) INCR'
incr1_txt VARCHAR2(16) INCR1'
incr2_txt VARCHAR2(16) INCR2'
incr3_txt VARCHAR2(16) INCR3'
incr4_txt VARCHAR2(16) INCR4'
other_txt VARCHAR2(16) 'OTHER'
piece_txt VARCHAR2(16) 'PIECE'
proxycopy_txt VARCHAR2(16) 'PROXY COPY'
spfile_txt VARCHAR2(16) 'SPFILE'
unavailable_txt VARCHAR2(16) 'UNAVAILABLE'
Constants (Backup Type Mask)
Name Data Type Value
BSdatafile_full BINARY_INTEGER 2**0
BSdatafile_incr BINARY_INTEGER 2**1
BSarchivelog BINARY_INTEGER 2**2
Constants (Command Type)
Name Data Type Value
unknownCmd_t BINARY_INTEGER 0
recoverCmd_t BINARY_INTEGER 1
rcvCopyCmd_t BINARY_INTEGER 2
obsoleteCmd_t BINARY_INTEGER 3
restoreCmd_t BINARY_INTEGER 4
blkRestoreCmd_t BINARY_INTEGER 5
Constants (Controlfile Type Mask)
Name Data Type Value
BScfile_all BINARY_INTEGER 2**0
BScfile_auto BINARY_INTEGER 2**1
Constants (Kind Mask)
Name Data Type Value Description
maxKind NUMBER   last real kind above
allKind NUMBER (maxKind*2) - 1 all real backup types
fullKind NUMBER dfCopy + proxyFull + buSet  
tagKind NUMBER fullKind + applyIncremental  
Constants (Recovery Action Type)
Name Data Type Value
full_act_t NUMBER 2**0
incremental_act_t NUMBER 2**1
redo_act_t NUMBER 2**2
offlineRange_act_t NUMBER 2**3
cleanRange_act_t NUMBER 2**4
implicitRange_act_t NUMBER 2**5
spanningRange_act_t NUMBER 2**6
createdatafile_act_t NUMBER 2**7
Constants (Recovery Container)
Name Data Type Value
offlineRangeRec_con_t NUMBER 2**0
proxyCopy_con_t NUMBER 2**1
imageCopy_con_t NUMBER 2**2
backupSet_con_t NUMBER 2**3
addredo_con_t NUMBER 2**4
deleted_con_t NUMBER 2**8
datafile_con_t NUMBER 2**9
Constants (Recovery Container Mask)
Name Data Type Value
backupMask_con_t NUMBER proxyCopy_con_t + imageCopy_con_t + backupSet_con_t;
tagMask_con_t NUMBER proxyCopy_con_t + imageCopy_con_t + backupSet_con_t;
Constants (Recovery Record Returning)
Name Data Type Value
getCfCopy NUMBER 0
getDfCopy NUMBER 1
getAnyProxy NUMBER 2
getCfBackup NUMBER 3
listCfCopy NUMBER 4
listDfCopy NUMBER 5
listCfBackup NUMBER 6
listDfBackup NUMBER 7
listAlBackup NUMBER 8
listDfProxy NUMBER 9
getRecovAction NUMBER 10
getAlBackup NUMBER 11
listAlCopy NUMBER 12
listBSet NUMBER 13
getSfBackup NUMBER 14
listSfBackup NUMBER 15
getAllBSet NUMBER 16
listAlProxy NUMBER 17
getRangeAlBackup NUMBER 18
Constants (Stuck Memory)
Name Data Type Value
stuckMemorySize NUMBER 50 * 1024 * 1024
Data Types -- data file record ... the definition has changed in 11.2.0.3
TYPE dfRec_t IS RECORD (
dfNumber         NUMBER,
dfCreationSCN    NUMBER,
dfCreationTime   DATE,
fileName         VARCHAR2(1024),
tsName           VARCHAR2(30),
tsNumber         NUMBER,
status           NUMBER,
blocks           NUMBER,
blockSize        NUMBER,
kbytes           NUMBER,
unrecovSCN       NUMBER,
stopSCN          NUMBER,
readOnly         NUMBER,
rfNumber         NUMBER,
inBackup         NUMBER,        -- if greater than 0 then
                                -- included_in_database_backup is set
auxName          VARCHAR2(1024),
dbincKey         NUMBER,
dfOfflineSCN     NUMBER, 
dfOnlineSCN      NUMBER, 
dfOnlineTime     DATE,
encrypt          NUMBER,         -- encrypt value 1=ON, 2=OFF, 3=CLEAR
foreignDbid      NUMBER,         -- foreign database id
pluggedRonly     BINARY_INTEGER, -- 1 for read-only. Otherwise, 0
pluginSCN        NUMBER,         -- plugin change#
pluginRlgSCN     NUMBER,         -- plugin resetlogs_change#
pluginRlgTime    DATE,           -- plugin resetlogs_time
newDfCreationSCN NUMBER,         -- plugin scn or creation scn
creation_thread  NUMBER,         -- creation thread
creation_size    NUMBER);        -- creation size

-- temp file record
TYPE tfRec_t IS RECORD (
tfNumber       NUMBER,
tfCreationSCN  NUMBER,
tfCreationTime DATE,
fileName       VARCHAR2(1024),
tsName         VARCHAR2(30),
tsNumber       NUMBER,
status         NUMBER,
isSFT          VARCHAR2(3),
blocks         NUMBER,
blockSize      NUMBER,
maxSize        NUMBER,
nextSize       NUMBER,
rfNumber       NUMBER,
dbincKey       NUMBER);

-- archived log record ... definition change in 10.2.0.3
TYPE alRec_t IS RECORD (
key                NUMBER,
recid              NUMBER,
stamp              NUMBER,
thread             NUMBER,
sequence           NUMBER,
fileName           VARCHAR2(1024),
lowSCN             NUMBER,
lowTime            DATE,
nextSCN            NUMBER,
nextTime           DATE,
rlgSCN             NUMBER,
rlgTime            DATE,
blocks             NUMBER,
blockSize          NUMBER,
status             VARCHAR2(1),
compTime           DATE,
duplicate          NUMBER,
isrdf              VARCHAR2(3),
compressed         VARCHAR2(3),
stby               VARCHAR2(1),
terminal           VARCHAR2(3),
site_key           NUMBER,
site_key_order_col NUMBER,
source_dbid        NUMBER);

-- recovery record ... definition change in 11.2.0.3
TYPE rcvRec_t IS RECORD(
-- *** Recovery Container Section ***
type_con             NUMBER(3),      -- recovery container type
key_con              NUMBER(15),     -- primary key
recid_con            NUMBER(10),     -- recid
stamp_con            NUMBER(10),     -- stamp
setStamp_con         NUMBER(10),     -- set count if backup set (null)
setCount_con         NUMBER(10),     -- set stamp if backup set (null)
bsRecid_con          NUMBER(10),     -- backup set recid (null)
bsStamp_con          NUMBER(10),     -- backup set stamp (null)
bsKey_con            NUMBER(15),     -- backup set key (null)
bsLevel_con          NUMBER(1),      -- backup set level (null)
bsType_con           VARCHAR2(1),    -- backup set type
elapseSecs_con       NUMBER(10),     -- backup set elapse seconds (null)
pieceCount_con       NUMBER(5),      -- backup set piece count (null)
fileName_con         VARCHAR2(1024), -- filename is a copy (or) piece (null)
tag_con              VARCHAR2(32),   -- tag (null) filled in by addAction() for backup sets
copyNumber_con       NUMBER(3),      -- backup set copy# (null) maxlimit 256
                                     -- filled in by addAction() only
status_con           VARCHAR2(1),    -- status (null)
blocks_con           NUMBER(10),     -- size of file in blocks (null)
blockSize_con        NUMBER(5),      -- block size (null)
deviceType_con       VARCHAR2(255),  -- device type required (null) filled in by
                                     -- addAction() for backup sets
compTime_con         DATE,           -- completion time
cfCreationTime_con   DATE,           -- controlfile creation time if offline range (null)
pieceNumber_con      NUMBER,
bpCompTime_con       DATE,
bpCompressed_con     VARCHAR2(3),
multi_section_con    VARCHAR2(1),    -- multi-section backup piece
-- *** Recovery Action Section ***
type_act             NUMBER(3),      -- recovery action type
fromSCN_act          NUMBER(15),
toSCN_act            NUMBER(15),
toTime_act           DATE,
rlgSCN_act           NUMBER(15),
rlgTime_act          DATE,
dbincKey_act         NUMBER(15),
level_act            NUMBER(1),
section_size_act     NUMBER,        
-- *** Recovery Object Section ***
dfNumber_obj         NUMBER(6),
dfCreationSCN_obj    NUMBER(15),
cfSequence_obj       NUMBER(15),     -- controlfile autobackup sequence
cfDate_obj           DATE,           -- controlfile autobackup date
logSequence_obj      NUMBER(10),
logThread_obj        NUMBER(4),
logRlgSCN_obj        NUMBER(15),
logRlgTime_obj       DATE,
logLowSCN_obj        NUMBER(15),
logLowTime_obj       DATE,
logNextSCN_obj       NUMBER(15),
logNextTime_obj      DATE,
logTerminal_obj      VARCHAR2(3),
cfType_obj           VARCHAR2(1),    -- controlfile type ('B' or 'S')
-- *** Retention Policy Section ***
keep_options         NUMBER(4),
keep_until           DATE,
-- *** optimization Action Section ***
afzSCN_act           NUMBER(15),
rfzTime_act          DATE,
rfzSCN_act           NUMBER(15),
-- *** media Action Section ***
media_con            VARCHAR2(80),   -- media volume name for backup piece
isrdf_con            VARCHAR2(3),
-- ** site specific information for recovery action ***
site_key_con         NUMBER,
-- *** plugged section ***
foreignDbid_obj      NUMBER,         -- foreign database id
pluggedRonly_obj     BINARY_INTEGER, -- 1 for read-only. Otherwise, 0
pluginSCN_obj        NUMBER,         -- plugin change#
pluginRlgSCN_obj     NUMBER,         -- plugin resetlogs change#
pluginRlgTime_obj    DATE,           -- plugin resetlogs time
-- ** sort order section ***
newDfCreationSCN_obj NUMBER,         -- plugin scn or creation scn
newToSCN_act         NUMBER,         -- plugin scn or checkpoint scn
newRlgSCN_act        NUMBER,         -- plugin rlgscn or rlgscn
newRlgTime_act       DATE,           -- plugin rlgtime or rlgtime
-- ** SPFILE specific data **
sfDbUniqueName_obj   VARCHAR2(30));

-- Backup Set record ... definition changed in 11.2.0.3
TYPE bsRec_t IS RECORD (
recid         NUMBER,
stamp         NUMBER,
key           NUMBER,
setStamp      NUMBER,
setCount      NUMBER,
bsType        VARCHAR2(1),
level         NUMBER,
elapseSecs    NUMBER,
compTime      DATE,
status        VARCHAR2(1),
pieceCount    NUMBER,
keep_options  NUMBER(4),
keep_until    DATE,
multi_section VARCHAR2(1));

-- Backup Piece record ... definition changed in 11.2.0.3
TYPE bpRec_t IS RECORD (
recid       NUMBER,
stamp       NUMBER,
key         NUMBER,
bskey       NUMBER,
setStamp    NUMBER,
setCount    NUMBER,
pieceNumber NUMBER,
copyNumber  NUMBER,
status      VARCHAR2(1),
compTime    DATE,
handle      VARCHAR2(1024),
tag         VARCHAR2(32),
deviceType  VARCHAR2(255),
media       VARCHAR2(80),
bytes       NUMBER,
compressed  VARCHAR2(3),
site_key    NUMBER);

-- Backupset Validation record
TYPE validBackupSetRec_t IS RECORD (
deviceType VARCHAR2(255),
tag        VARCHAR2(32), -- may be null
copyNumber NUMBER,       -- null if code 2 or 3
code       NUMBER);      -- 1 => same copy#
                         -- 2 => mix of copy#s, but same tag
                         -- 3 => mix of copy#s and tags

TYPE incarnation_t IS RECORD (
INCARNATION#            NUMBER,
RESETLOGS_CHANGE#       NUMBER,
RESETLOGS_TIME          DATE,
PRIOR_RESETLOGS_CHANGE# NUMBER,
PRIOR_RESETLOGS_TIME    DATE,
STATUS                  VARCHAR2(7),
RESETLOGS_ID            NUMBER,
PRIOR_INCARNATION#      NUMBER);

TYPE incarnation_set IS VARRAY(1) OF incarnation_t;

-- backup history
TYPE bhistoryRec_t IS RECORD (
dfNumber      NUMBER,
create_scn    NUMBER,
reset_scn     NUMBER,
reset_time    DATE,
ckp_scn       NUMBER,
ckp_time      DATE,
stop_scn      NUMBER,
logThread     NUMBER,
logSequence   NUMBER,
setStamp      NUMBER,
setCount      NUMBER,
compTime      DATE,
nbackups      NUMBER,
logTerminal   VARCHAR2(3),
next_scn      NUMBER,
pluggedRonly  BINARY_INTEGER, -- 1 for read-only. Otherwise, 0
pluginSCN     NUMBER,
pluginRlgSCN  NUMBER,
pluginRlgTime DATE,
newcreate_scn NUMBER, -- create_scn or pluginSCN
newreset_scn  NUMBER, -- reset_scn or pluginRlgSCN
newreset_time DATE);  -- reset_time or pluginRlgTime

-- aged file record
TYPE agedFileRec_t IS RECORD (
type  NUMBER,
key   NUMBER,
stamp NUMBER);

TYPE lbRec_t IS RECORD (
list_order1            NUMBER, -- just hint to correctly order records
list_order2            NUMBER, -- just hint to correctly order records
pkey                   NUMBER, -- primary key
-- row part
backup_type            VARCHAR2(32), -- backup type (BACKUP SET/COPY/PROXY COPY)
-- file part
file_type        VARCHAR2(32), -- file type (DATAFILE/CONTROLFILE/SPFILE/REDO LOG/PIECE)
-- Common part. This part is shared by rows returned from listBackup.
keep                   VARCHAR2(3),
keep_until             DATE,
keep_options           VARCHAR2(13),
status           VARCHAR2(16), -- piece/copy status (AVAILABLE/UNAVAILABLE/EXPIRED/OTHER)
fname                  VARCHAR2(1024), -- piece or copy name
tag                    VARCHAR2(32),   -- piece or copy tag
media                  VARCHAR2(80),
recid                  NUMBER,
stamp                  NUMBER,
device_type            VARCHAR2(255),
block_size             NUMBER,
completion_time        DATE,
is_rdf                 VARCHAR2(3),
compressed             VARCHAR2(3),
obsolete               VARCHAR2(3),
keep_for_dbpitr        VARCHAR2(3),
bytes                  NUMBER,
-- BACKUP SET part. Valid only when backup_type is 'BACKUP SET'
bs_key                 NUMBER,
bs_count               NUMBER,
bs_stamp               NUMBER,
bs_type                VARCHAR2(32), -- backup set type (DATAFILE/ARCHIVED LOG)
bs_incr_type           VARCHAR2(32),
bs_pieces              NUMBER,
bs_copies              NUMBER,
bs_completion_time     DATE,
bs_status        VARCHAR2(16), -- backup set status (AVAILABLE/UNAVAILABLE/EXPIRED/OTHER)
bs_bytes               NUMBER,
bs_compressed          VARCHAR2(3), -- If backup set is compressed: (Yes/No/Other)
bs_tag                 VARCHAR2(1024), -- List of all tags of pieces.
-- We don't repeat same tags. Tags divided by commas.
bs_device_type         VARCHAR2(255), -- List of device types of pieces.
-- Device types are divided by commas.
-- BACKUP PIECE part. Valid only when file_type is 'PIECE' and backup_type is 'BACKUP SET'.
bp_piece#              NUMBER,
bp_copy#               NUMBER,
-- DATAFILE part Valid only when file_type is 'DATAFILE', 'CONTROLFILE', or 'SPFILE'
df_file#               NUMBER,
df_tablespace          VARCHAR2(30),
df_resetlogs_change#   NUMBER,
df_creation_change#    NUMBER,
df_checkpoint_change#  NUMBER,
df_ckp_mod_time        DATE,
df_incremental_change# NUMBER,
-- REDO LOG part. This part is valid only when file_type is 'REDO LOG'
rl_thread#             NUMBER,
rl_sequence#           NUMBER,
rl_resetlogs_change#   NUMBER,
rl_first_change#       NUMBER,
rl_first_time          DATE,
rl_next_change#        NUMBER,
rl_next_time           DATE,
-- SPFILE part
sf_db_unique_name      VARCHAR2(30));

-- Note: The definition of this type has changed since 11.2.0.2
TYPE lbDfRec_t IS RECORD (
dfRec          dfRec_t,
-- This is the minimum checkpoint_change# of the backup that are kept
-- for retention policy and its corresponding resetlogs_change#.
-- A full backup of this datafile is kept if its checkpoint_change# is
-- greater than fullmin_scn and its resetlogs_change# is greater
-- that fullmin_scn or equal to fullmin_rlgscn.
fullmin_scn    NUMBER,
fullmin_rlgscn NUMBER,
-- This is the minimum checkpoint_change# of the backup that are kept
-- for retention policy and its corresponding resetlogs_change#.
-- A incremental backup of this datafile is kept if its checkpoint_change#
-- is greater than incrmin_scn and its resetlogs_change# is greater
-- than incrmin_scn or equal to incrmin_rlgscn.
incrmin_scn    NUMBER,
incrmin_rlgscn NUMBER,
-- This is the minimum checkpoint_change# of its backup that are kept
-- for archived logs attribute and its corresponding resetlogs_change#.
-- All archivelogs and its backups are kept if its first_change# is
-- greater than the logmin_scn and its resetlogs_change# is greater
-- thatn logmin_scn or equal to logmin_rlgscn.
logmin_scn    NUMBER,
logmin_rlgscn NUMBER);

TYPE lbDfRecTab_t  IS TABLE OF lbDfRec_t INDEX BY BINARY_INTEGER;
TYPE lbRecTab_t    IS TABLE OF lbRec_t INDEX BY BINARY_INTEGER;
TYPE lbRecVar_t    IS VARRAY(1) OF lbRec_t;
TYPE rcvRecTabI_t  IS TABLE OF rcvRec_t INDEX BY BINARY_INTEGER;
TYPE rcvRecTabII_t IS TABLE OF rcvRecTabI_t INDEX BY BINARY_INTEGER;
TYPE dfRecTab_t    IS TABLE OF dfRec_t INDEX BY BINARY_INTEGER;
TYPE numTab_t      IS TABLE OF number INDEX BY BINARY_INTEGER;
TYPE lbCursor_t    IS REF CURSOR;

TYPE lbState_t IS RECORD (
-- The collection table lbRecOutTab keeps track of the rows which should
-- returned by the function listBackup. The function listBackup will loop
-- until it does not fill lbRecOutTab with at least one element.
lbRecOutTab         lbRecTab_t,
lbRecOutTab_count   BINARY_INTEGER,
-- The collection table lbRecTmpTab keeps track of the backup datafiles and
-- backup archived log rows which are part of the backup set.
lbRecTmpTab         lbRecTab_t,
-- The collection lbRecCmn keeps track of the backup set attributes.
lbRecCmn            lbRec_t,
-- The collection table lbDfRecTab contains the list of all database files
-- which ever existed after untilSCN.
lbDfRecTabUs        lbDfRecTab_t,
-- The collection table lbDfRecTab contains the list of all database files
-- which ever existed.
lbDfRecTab          dfRecTab_t,
-- This variable hols the maximum number of the datafile. It is used for
-- indextin of lbDfRecTab.
lbMaxDfNumber       NUMBER,
-- For keep backups we need to know the current time.
lbNowTime           DATE,
-- The table piece_count stores number of pieces in each copy. The variable
-- copy_count says how many copies we have.
lbPieceCountTab     numTab_t,
lbCopyCount binary_integer,
-- Must Keep List is a table of rcvRecTabI_t indexed by binary_integer
-- which itself is a table of rcvRec_t
lbMkTab             rcvRecTabII_t,
-- Must Keep Incremental List is a table of rcvRecTabI_t indexed by
-- binary_integer which itself is a table of rcvRec_t
lbMkITab            rcvRecTabII_t,
-- The variable lbMinGrsp stands for minimum guaranteed restore point.
-- An archived log backup set is obsolete if all rl_first_change#
-- in the backup set is less than lbMinGrsp. No resetlogs information
-- is compared. The redo log copies DOES NOT FOLLOW this rule. We
-- keep the redo log copies only if needed by guaranteed restore point.
-- The idea of keeping the backupset of redo log since the oldest GRP is
-- to flashback to GRP2 from GRP1 (where GRP2 > GRP1) because it
-- will require archivelogs outside the range listed by grsp table
-- (from_scn - to_scn column).
lbMinGrsp           NUMBER,
-- The variable lbFbUntilTime stands for Flashback Until Time.
-- An archived log backup set is obsolete if all rl_first_time in the
-- backup set is less than lbFbUntilTime. No resetlogs information is
-- compared. The redo log copies (that is archived logs and proxy
-- copies) follow the same rule.
lbFbUntilTime       DATE,
-- The variable lbRlKeepRlgSCN is the resetlogs_change# associated with
-- the lbRlKeepSCN. It is used in conjunction with lbRlKeepSCN to
-- decide an obsolete archived log. When NULL, the resetlogs_change#
-- is unknown.
lbRlKeepRlgSCN      NUMBER,
-- The variable lbRlKeepSCN says that archived log backup set is
-- obsolete if the rl_first_change# in the backup set is less than
-- lbRlKeepSCN and its resetlogs_change# greater than lbRlKeepSCN and
-- equal to lbRlKeepRlgSCN.
-- The redo logs copies (that is archived logs and proxy copies)
-- follow the same rule.
lbRlKeepSCN         NUMBER,
-- If either lbObsoleteRetention or lbObsoleteKeep is set to TRUE when the
-- current backup processed by listBackup is obsolete.
-- If lbObsoleteRetention is TRUE, then the backup is obsolete because of
-- retention policy. If lbObsoleteKeep is TRUE, then the backup is obsolete
-- because of its keep attributes.
lbObsoleteRetention BOOLEAN,
lbKeepForDBPITR     BOOLEAN,
lbObsoleteKeep      BOOLEAN,
lbNeedObsoleteData  BOOLEAN);

-- In case that listBackup is not called from pipeline function, then there is no need
-- for the called to save and maintain the state: the function will use state from the
-- package.
lbStatePck lbState_t;

TYPE failureRec_t IS RECORD (
priority     VARCHAR2(8),
failureId    NUMBER,
parentId     NUMBER,
childCount   NUMBER,
description  VARCHAR2(1024),
timeDetected DATE,
status       VARCHAR2(12),
impacts      VARCHAR2(1024));

TYPE repairRec_t IS RECORD (
type        NUMBER,
failureidx  NUMBER,
repairidx   NUMBER,
description VARCHAR2(1024));

TYPE repairParmsRec_t IS RECORD (
type       NUMBER,
failureidx NUMBER,
repairidx  NUMBER,
name       VARCHAR2(256),
value      VARCHAR2(512));

TYPE repairOptionRec_t IS RECORD (
optionidx   NUMBER,
description VARCHAR2(1024));

TYPE repairStepRec_t IS RECORD (
type          NUMBER,
failureidx    NUMBER,
repairidx     NUMBER,
repairstepidx NUMBER,
workingrepair NUMBER,
description   VARCHAR2(1024),
repairscript  VARCHAR2(1024));
Dependencies
DBA_CAPTURE V$OFFLINE_RANGE V_$UNUSABLE_BACKUPFILE_DETAILS
DBMS_OUTPUT V$PARAMETER V_LBRECSETIMPL_T
DUAL V$PROXY_ARCHIVEDLOG V_RANGERECSETIMPL_T
PLITBLM V$PROXY_DATAFILE X$IR_REPAIR_OPTION
TS$ V$RMAN_CONFIGURATION X$IR_REPAIR_STEP
UNDO$ V$STANDBY_LOG X$IR_WORKING_REPAIR_SET
V$ARCHIVED_LOG V$TABLESPACE X$IR_WR_PARAM
V$ARCHIVE_DEST V_$BACKUP_ARCHIVELOG_DETAILS X$KCCBF
V$BACKUP_DATAFILE V_$BACKUP_ARCHIVELOG_SUMMARY X$KCCDC
V$BACKUP_PIECE V_$BACKUP_CONTROLFILE_DETAILS X$KCCDI2
V$BACKUP_REDOLOG V_$BACKUP_CONTROLFILE_SUMMARY X$KCCFE
V$BACKUP_SET V_$BACKUP_COPY_DETAILS X$KCCFLE
V$BACKUP_SPFILE V_$BACKUP_COPY_SUMMARY X$KCCFN
V$CONTAINERS V_$BACKUP_DATAFILE_DETAILS X$KCCNRS
V$DATABASE V_$BACKUP_DATAFILE_SUMMARY X$KCCPD
V$DATABASE_BLOCK_CORRUPTION V_$BACKUP_PIECE_DETAILS X$KCCRSP
V$DATABASE_INCARNATION V_$BACKUP_SET_DETAILS X$KCCRT
V$DATAFILE_COPY V_$BACKUP_SET_SUMMARY X$KCCTF
V$FOREIGN_ARCHIVED_LOG V_$BACKUP_SPFILE_DETAILS X$KCCTIR
V$IR_FAILURE V_$BACKUP_SPFILE_SUMMARY X$KCCTS
V$IR_FAILURE_SET V_$PROXY_ARCHIVELOG_DETAILS X$KCPDBINC
V$IR_MANUAL_CHECKLIST V_$PROXY_ARCHIVELOG_SUMMARY X$KCVFH
V$IR_REPAIR V_$PROXY_COPY_DETAILS X$KCVFHTMP
V$LOG V_$PROXY_COPY_SUMMARY X$KSPPCV2
V$LOGFILE V_$RMAN_BACKUP_JOB_DETAILS X$KSPPI
V$LOG_HISTORY V_$RMAN_BACKUP_SUBJOB_DETAILS  
Documented No
Exceptions
Error Code Reason
ORA-01410 ROWID_INVALID: Invalid rowid format
ORA-20021 Database not set
ORA-20203 Translation already started
ORA-20204 Translation not started
ORA-20300 Not supported without recovery catalog
ORA-28516 ROWID_BAD_BLOCK: Block is beyond end of file
First Available 8.0
Public Variables
Name Data Type
SESSION_FROMTIME DATE
SESSION_KEY NUMBER
SESSION_UNTILTIME DATE
Security Model Owned by SYS with EXECUTE granted to the SELECT_CATALOG_ROLE role.
Source {ORACLE_HOME}/rdbms/admin/dbmsrman.sql
Subprograms
BMRADDCORRUPTTABLE GETUNTILTIME SETGETSINCELASTBACKEDAL
CLRSITENAME GETVALIDBACKUPSET SETLIKEPATTERN
COMPUTERECOVERYACTIONS INITIALIZE SETNEEDOBSOLETEDATA
CREATEFAILURELIST ISARCHIVEDLOGMISSING SETORSFILE
DBUNIQUENAMEISSTANDBY ISBACKUPTYPEMATCH SETPDBID
DUMPPKGSTATE ISBSRECCACHEMATCH SETRAFLAGS
DUMPSTATE ISDEVICETYPEALLOCATED SETRCVRECBACKUPAGE
FINDARCHIVEDLOGBACKUP ISINFAILURELIST SETRECLRECID
FINDCONTROLFILEBACKUP ISPDBSCNORPHAN SETRECOVERYDESTFILE
FINDLOGBREAKPOINT ISRECLRECID SETREDOLOGDELETIONPOLICY
FINDOFFLINERANGECOPY ISSTATUSMATCH SETSITENAME
FINDRANGEARCHIVEDLOGBACKUP ISTRANSLATEDDBID SETSTANDBY
FINDSPFILEBACKUP ISTRANSLATEDFNO SETTAG
FINDVALIDBACKUPSET ISTRANSLATEDPDBID SETTOLOG
GETACTUALDBINC LISTBACKUP SETUNTILLOG
GETALBACKUPHISTORY LISTGETARCHIVEDLOGBACKUP SETUNTILRESETLOGS
GETALLBACKUPSET LISTGETARCHIVEDLOGCOPY SETUNTILSCN
GETAPPLIEDAL LISTGETBACKUPSETFILES SETUNTILTIME
GETAPPLIEDSCN LISTGETCONTROLFILEBACKUP SET_PACKAGE_CONSTANTS
GETARCHIVEDLOG LISTGETCONTROLFILECOPY SKIPTABLESPACE
GETARCHIVEDLOGBACKUP LISTGETDATAFILEBACKUP STAMP2DATE
GETARCHIVEDNEXTSCN LISTGETDATAFILECOPY SV_GETSESSIONFROMTIMERANGE
GETBACKEDUPFILES LISTGETDBINCARNATION SV_GETSESSIONKEY
GETBACKUPHISTORY LISTGETDBSITE SV_GETSESSIONUNTILTIMERANGE
GETBACKUPPIECE LISTGETPROXYARCHIVEDLOG SV_SETSESSIONKEY
GETBSBACKUPHISTORY LISTGETPROXYDATAFILE SV_SETSESSIONTIMERANGE
GETCHECKPOINT LISTGETRESTOREPOINT TRANSLATEALLBACKUPSET
GETCLONENAME LISTGETSPFILEBACKUP TRANSLATEALLDATAFILE
GETCONFIG LISTGETTABLESPACE TRANSLATEARCHIVEDLOGCANCEL
GETCONTROLFILEBACKUP LISTROLLBACKSEGTABLESPACE TRANSLATEARCHIVEDLOGKEY
GETCONTROLFILECOPY LISTTRANSLATEARCHIVEDLOGBACKUP TRANSLATEARCHIVEDLOGNAME
GETCOPYOFDATAFILE LISTTRANSLATEARCHIVEDLOGCOPY TRANSLATEARCHIVEDLOGPATTERN
GETCURRENTINCARNATION LISTTRANSLATEBACKUPSETFILES TRANSLATEARCHIVEDLOGSCNRANGE
GETDATAFILE LISTTRANSLATECONTROLFILEBACKUP TRANSLATEARCHIVEDLOGSEQRANGE
GETDATAFILECOPY LISTTRANSLATECONTROLFILECOPY TRANSLATEARCHIVEDLOGTIMERANGE
GETDBUNIQUENAME LISTTRANSLATEDATAFILEBACKUP TRANSLATEBACKUPFILE
GETDCBACKUPHISTORY LISTTRANSLATEDATAFILECOPY TRANSLATEBACKUPPIECEBSKEY
GETDFBACKUPHISTORY LISTTRANSLATEDBINCARNATION TRANSLATEBACKUPPIECEHANDLE
GETDROPOSFILES LISTTRANSLATEDBSITE TRANSLATEBACKUPPIECEKEY
GETDROPSCN LISTTRANSLATEPROXYARCHIVEDLOG TRANSLATEBACKUPPIECETAG
GETENCRYPTTSCOUNT LISTTRANSLATEPROXYDATAFILE TRANSLATEBACKUPSETKEY
GETFAILURE LISTTRANSLATEPROXYDFRECID TRANSLATEBACKUPSETRECID
GETINCARNATIONKEY LISTTRANSLATERESTOREPOINT TRANSLATEBPBSKEYCANCEL
GETINCREMENTALSCN LISTTRANSLATESPFILEBACKUP TRANSLATECONTROLFILECOPYKEY
GETMANUALREPAIR NUM2DISPLAYSIZE TRANSLATECONTROLFILECOPYNAME
GETMAXCOPYNO PRINTRECOVERYACTIONS TRANSLATECONTROLFILECOPYTAG
GETMAXREDOSCN REPORTGETDFDEL TRANSLATECORRUPTLIST
GETMAXSCN REPORTTRANSLATEDFDEL TRANSLATEDATABASE
GETNEXTAVAILABLESCN RESETALL TRANSLATEDATAFILE
GETOFFLINERANGECOPY RESETDEVICETYPE TRANSLATEDATAFILECANCEL
GETONLINELOG RESETPDBIDLIST TRANSLATEDATAFILECOPY
GETPACKAGEVERSION RESETRECLRECID TRANSLATEDATAFILECOPYFNO
GETPARENTINCARNATION RESETTHISBACKUPAGE TRANSLATEDATAFILECOPYKEY
GETPRIMARYDFNAME RESETUNTIL TRANSLATEDATAFILECOPYNAME
GETPROXYCOPY SEC2DISPLAYTIME TRANSLATEDATAFILECOPYTAG
GETRCVREC SETALLFLAG TRANSLATEFAILURE
GETRECOVERYACTION SETALLINCARNATIONS TRANSLATEMANUALREPAIR
GETREDOLOGDELETIONPOLICY SETARCHIVEDLOGRECORD TRANSLATEONLINELOGS
GETREPAIR SETARCHIVEFILESCOPEATTRIBUTES TRANSLATEPDB2NAME
GETREPAIROPTION SETBACKUPFILESCOPEATTRIBUTES TRANSLATEPDBNAME
GETREPAIRPARMS SETCANAPPLYANYREDO TRANSLATEPROXYCOPYHANDLE
GETREPAIRSCRIPTNAME SETCANCONVERTCF TRANSLATEPROXYCOPYKEY
GETREPAIRSTEP SETCANHANDLETRANSPORTABLETBS TRANSLATEPROXYCOPYTAG
GETREQUIREDSCN SETCOMPLETEDRANGE TRANSLATEREPAIR
GETRESTOREPOINT SETCOMPUTERECOVERYACTIONMASKS TRANSLATEREPAIROPTION
GETRESTORERANGESET SETDATABASE TRANSLATEREPAIRPARMS
GETRETENTIONPOLICY SETDBIDTRANSCLAUSE TRANSLATEREPAIRSTEP
GETSCNFORAPPLIEDPOLICY SETDBINCKEY TRANSLATESEEKBPBSKEY
GETSITEKEY SETDEBUGOFF TRANSLATETABLESPACE
GETSITENAME SETDEBUGON TRANSLATETEMPFILE
GETSPACERECL SETDEVICETYPE TRIMRECOVERYACTIONS
GETSPFILEBACKUP SETDEVICETYPEANY VALIDATESTANDBYCONFIG
GETTEMPFILE SETFROM WASFILEOFFLINE
GETUNTILSCN    
 
BMRADDCORRUPTTABLE
Creates a corruption table dbms_rcvman.bmrAddCorruptTable(
dfNUMBER  OUT NUMBER,
blkNUMBER OUT NUMBER,
range     OUT NUMBER,
first     IN  BOOLEAN);
set serveroutput on

DECLARE
 dfn  NUMBER;
 blkn NUMBER;
 rng  NUMBER;
BEGIN
  dbms_rcvman.bmrAddCorruptTable(dfn, blkn, rng, TRUE);
  dbms_output.put_line('DataFile: ' || TO_CHAR(dfn));
  dbms_output.put_line('Block#: ' || TO_CHAR(blkn));
  dbms_output.put_line('Range: ' || TO_CHAR(rng));
END;
/
 
CLRSITENAME
Clear package variables set by setSiteName procedure dbms_rcvman.clrSiteName;
exec dbms_rcvman.clrsitename;
 
COMPUTERECOVERYACTIONS
Undocumented dbms_rcvman.computeRecoveryActions(
fno           IN NUMBER,                -- Datafile NUMBER
crescn        IN NUMBER,                -- Datafile creation SCN
df_rlgscn     IN NUMBER  DEFAULT NULL,  -- Datafile resetlogs SCN
  -- NULL if RESTORE command, else this is the value in the
  -- datafile header for the datafile being recovered
df_rlgtime    IN DATE    DEFAULT NULL,  -- Datafile resetlogs time
  -- Null if df_rlgscn is null, else value from datafile header
df_ckpscn     IN NUMBER  DEFAULT NULL,  -- Datafile checkpoint SCN
  -- Null if df_rlgscn is null, else value from datafile header
offlscn       IN NUMBER  DEFAULT 0,     -- kccfeofs
onlscn        IN NUMBER  DEFAULT 0,     -- kccfeonc null if offlscn is null
onltime       IN DATE    DEFAULT NULL,  -- kccfeonc_time
cleanscn      IN NUMBER  DEFAULT 0,     -- kccfecps if either SOR or WCC set, else null
clean2scn     IN NUMBER  DEFAULT 0,     
  -- CF ckpt SCN if WCC set, infinity if SOR bit set else null
clean2time    IN DATE    DEFAULT NULL,  -- cf ckpt time if WCC, SYSDATE if SOR
allowfuzzy    IN BOOLEAN DEFAULT FALSE,
  -- TRUE if can be fuzzy at until SCN/time, FALSE if not
partial_rcv   IN BOOLEAN DEFAULT FALSE, -- TRUE if can do partial recovery, else FALSE
cf_scn        IN NUMBER  DEFAULT NULL,  -- controlfile checkpoint SCN (NULL if none mounted)
cf_cretime    IN DATE    DEFAULT NULL,  -- controlfile creation time (NULL if none mounted)
cf_offrrid    IN NUMBER DEFAULT NULL,   -- recid of oldest offline range in controlfile
  -- (NULL if none mounted)
allCopies     IN BOOLEAN DEFAULT FALSE,       -- TRUE = stack all valid copies of a BU set
df_cretime    IN DATE           DEFAULT NULL, -- datafile creation time
rmanCmd       IN BINARY_INTEGER DEFAULT unknownCmd_t,
foreignDbid   IN NUMBER         DEFAULT 0,
pluggedRonly  IN BINARY_INTEGER DEFAULT 0,
pluginSCN     IN NUMBER         DEFAULT 0,
pluginRlgSCN  IN NUMBER         DEFAULT 0,
pluginRlgTime IN DATE           DEFAULT NULL)
RETURN BINARY_INTEGER;

Name Data Type Value
SUCCESS BINARY_INTEGER 0
UNAVAILABLE BINARY_INTEGER 1
AVAILABLE BINARY_INTEGER 2
RESTORABLE BINARY_INTEGER 3
NO_ACTION BINARY_INTEGER 4
TBD
 
CREATEFAILURELIST
Called to initialize a failure list in dbms_rcvman package dbms_rcvman.createfailurelist(
first_call  IN BOOLEAN,
failureId   IN NUMBER,
for_exclude IN BOOLEAN);
TBD
 
DBUNIQUENAMEISSTANDBY
Return TRUE if the database site identified by current db_unique_name is standby dbms_rcvman.dbUniqueNameIsStandby RETURN NUMBER;
set serveroutput on

DECLARE
 i PLS_INTEGER;
BEGIN
  i := dbms_rcvman.dbUniqueNameIsStandby;
  dbms_output.put_line(i);
END;
/
 
DUMPPKGSTATE
Debugging procedure dbms_rcvman.dumpPkgState(msg IN VARCHAR2 DEFAULT NULL);
exec dbms_rcvman.dumpPkgState;

exec dbms_rcvman.dumpPkgState('/u01/tmp/pkgdump.dmp');
 
DUMPSTATE
Debugging function dbms_rcvman.dumpstate(lineno IN NUMBER) RETURN VARCHAR2;
BEGIN
  FOR i IN 1..14 LOOP
    dbms_output.put_line(dbms_rcvman.dumpstate(i));
  END LOOP;
END;
/
 
FINDARCHIVEDLOGBACKUP
Finds a backup set containing the given archived log

Overload 1
dbms_rcvman.findarchivedlogbackup(
thread    IN NUMBER,
sequence  IN NUMBER,
lowSCN    IN NUMBER,
allCopies IN BOOLEAN DEFAULT FALSE);
Deprecated as of 11g
Finds a backup set containing the given archived log

Overload 2
dbms_rcvman.findarchivedlogbackup(
thread#     IN  NUMBER,
sequence#   IN  NUMBER,
low_scn     IN  NUMBER,
type        OUT NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
device_type OUT VARCHAR2)
RETURN NUMBER;
Deprecated as of 8.1.6
 
FINDCONTROLFILEBACKUP
allCopies = TRUE fetches duplex ones

Overload 1
dbms_rcvman.findControlFileBackup(allCopies IN BOOLEAN DEFAULT FALSE);
exec dbms_rcvman.setDatabase(NULL,NULL,NULL,NULL,1746737380);

exec dbms_rcvman.findControlFileBackup;
Overload 2 dbms_rcvman.findControlFileBackup(
type        OUT NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
fname       OUT VARCHAR2,
device_type OUT VARCHAR2,
ckp_scn     OUT NUMBER)
RETURN NUMBER;
Obsolete: For versions 8.0.4 to 8.1.5
Overload 3 dbms_rcvman.findControlFileBackup(
type        OUT NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
fname       OUT VARCHAR2,
device_type OUT VARCHAR2,
ckp_scn     OUT NUMBER,
rlg_scn     OUT NUMBER,
blksize     OUT NUMBER)
RETURN NUMBER;
Obsolete: 8.1.5 only
 
FINDLOGBREAKPOINT (new 12.1)
Finds the point where archived log continuity breaks dbms_rcvman.findLogBreakPoint(
logBreakPointScn      OUT NUMBER,
logBreakPointTime     OUT DATE,
logBreakPointDbIncKey OUT NUMBER,
logBreakPointRlgScn   OUT NUMBER,
logBreakPointRlgTime  OUT DATE,
fromSCN               IN  NUMBER,
untilSCN              IN  NUMBER,
isOrs                 IN  NUMBER)
RETURN BOOLEAN;
TBD
 
FINDOFFLINERANGECOPY
Begins the search for a controlfile copy containing a specified offline range dbms_rcvman.findofflinerangecopy(
offr_recid  IN NUMBER,
offr_ckpscn IN NUMBER,
cf_cretime  IN DATE,
dbinc_key   IN NUMBER);
Deprecated as of 8.1.6
 
FINDRANGEARCHIVEDLOGBACKUP
Finds all the backup sets that are required to restore the archivelog specified in the range dbms_rcvman.findrangearchivedlogbackup(
minthread   IN NUMBER,
minsequence IN NUMBER,
minlowSCN   IN NUMBER,
maxthread   IN NUMBER,
maxsequence IN NUMBER,
maxlowSCN   IN NUMBER,
allCopies   IN BOOLEAN DEFAULT FALSE);
TBD
 
FINDSPFILEBACKUP
allCopies = TRUE fetches duplex ones redundancy determine the NUMBER of redundant copies to fetch dbms_rcvman.findspfilebackup(
allCopies  IN BOOLEAN DEFAULT FALSE,
redundancy IN NUMBER  DEFAULT NULL,
rmanCmd    IN NUMBER  DEFAULT unknownCmd_t);
TBD
 
FINDVALIDBACKUPSET
Use the findValidBackupSetRec public variable to save a backupset record for later use as an input argument to this procedure

Overload 1
dbms_rcvman.findvalidbackupset(
backupSetRec  IN rcvRec_t,
deviceType    IN VARCHAR2       DEFAULT NULL,
tag           IN VARCHAR2       DEFAULT NULL,
available     IN NUMBER         DEFAULT TRUE#,  -- for compat.
unavailable   IN NUMBER         DEFAULT FALSE#, -- for compat.
deleted       IN NUMBER         DEFAULT FALSE#, -- for compat.
expired       IN NUMBER         DEFAULT FALSE#, -- for compat.
availableMask IN BINARY_INTEGER DEFAULT NULL);  -- for compat.
TBD
Overload 2 dbms_rcvman.findvalidbackupset(
backupSetRec  IN bsRec_t,
deviceType    IN VARCHAR2       DEFAULT NULL,
tag           IN VARCHAR2       DEFAULT NULL,
available     IN NUMBER         DEFAULT TRUE#,  -- for compat.
unavailable   IN NUMBER         DEFAULT FALSE#, -- for compat.
deleted       IN NUMBER         DEFAULT FALSE#, -- for compat.
expired       IN NUMBER         DEFAULT FALSE#, -- for compat.
availableMask IN BINARY_INTEGER DEFAULT NULL);  -- for compat.
TBD
 
GETACTUALDBINC (new 12.1)
Returns the key of the incarnation that a previous set until performed with allIncarnations = TRUE# ended up using when the current incarnation was not selected. This is a recovery catalog only function. dbms_rcvman.getActualDBInc RETURN NUMBER;
SELECT dbms_rcvman.getActualDBInc
FROM dual;
 
GETALBACKUPHISTORY
Retrieve Archive Log backup history dbms_rcvman.getALBackupHistory(
backedUpDev IN  VARCHAR2,
first       IN  BOOLEAN,
bhistoryRec OUT NOCOPY bhistoryRec_t,
doingCmd    IN  VARCHAR2 DEFAULT NULL,
keepTag     IN  VARCHAR2 DEFAULT NULL,
toDest1     IN  VARCHAR2 DEFAULT NULL,
toDest2     IN  VARCHAR2 DEFAULT NULL,
toDest3     IN  VARCHAR2 DEFAULT NULL,
toDest4     IN  VARCHAR2 DEFAULT NULL);
TBD
 
GETALLBACKUPSET
Undocumented dbms_rcvman.getAllBackupSet(rcvRec OUT NOCOPY rcvRec_t);
TBD
 
GETAPPLIEDAL
Undocumented dbms_rcvman.getAppliedAl(first IN BOOLEAN, agedFileRec OUT NOCOPY agedFileRec_t);
TBD
 
GETAPPLIEDSCN
Returns the SCN till where the logs are applied at physical standby database dbms_rcvman.getAppliedSCN(
appscn  OUT NUMBER,
rlgscn  OUT NUMBER,
alldest IN  NUMBER);
set serveroutput on

DECLARE
 ascn NUMBER;
 rscn NUMBER;
BEGIN
  dbms_rcvman.getAppliedSCN(ascn, rscn, dbms_rcvman.TRUE#);
  dbms_output.put_line(ascn);
  dbms_output.put_line(rscn);
END;
/
 
GETARCHIVEDLOG
Retrieves the recid and stamp for each archived log, one at a time until null is returned

Overload 1
dbms_rcvman.getArchivedLog(
alRec       OUT NOCOPY alRec_t,
closeCursor IN  BOOLEAN DEFAULT FALSE);
TBD
Overload 2 dbms_rcvman.getArchivedLog(
recid      OUT NUMBER,
stamp      OUT NUMBER,
thread#    OUT NUMBER,
sequence#  OUT NUMBER,
low_scn    OUT NUMBER,
nxt_scn    OUT NUMBER,
fname      OUT VARCHAR2,
reset_scn  OUT NUMBER,
block_size OUT NUMBER,
blocks     OUT NUMBER);
Deprecated as of 8.1.6
 
GETARCHIVEDLOGBACKUP
Returns the record for the backup set. The return value is one of: SUCCESS, AVAILABLE, UNAVAILABLE. dbms_rcvman.getArchivedLogBackup(rcvRec OUT NOCOPY rcvRec_t)
RETURN BINARY_INTEGER;
Deprecated as of 11g
 
GETARCHIVEDNEXTSCN
Return the maximum next SCN to which the database can be recovered using archived logs dbms_rcvman.getArchivedNextSCN RETURN NUMBER;
SELECT dbms_rcvman.getArchivedNextSCN
FROM dual;
 
GETBACKEDUPFILES
Undocumented dbms_rcvman.getBackedUpFiles(
first       IN  BOOLEAN,
agedFileRec OUT NOCOPY agedFileRec_t);
TBD
 
GETBACKUPHISTORY
Retrieve Data File backup history

Overload 1
dbms_rcvman.getBackupHistory(
dfRec IN dfRec_t,
backedUpDev      IN  VARCHAR2,
nbackupsFlag     IN  NUMBER,
bscompletionFlag IN  NUMBER,
nbackups         OUT NUMBER,
bscompletion     OUT DATE);
Deprecated as of 9.2.0.1
Retrieve Archive Log backup history

Overload 2
dbms_rcvman.getBackupHistory(
alRec            IN  alRec_t,
backedUpDev      IN  VARCHAR2,
nbackupsFlag     IN  NUMBER,
bscompletionFlag IN  NUMBER,
nbackups         OUT NUMBER,
bscompletion     OUT DATE);
Deprecated as of 9.2.0.1
Overload 3 dbms_rcvman.getBackupHistory(
bpRec            IN  bpRec_t,
backedUpDev      IN  VARCHAR2,
nbackupsFlag     IN  NUMBER,
bscompletionFlag IN  NUMBER,
nbackups         OUT NUMBER,
bscompletion     OUT DATE,
toDest1          IN  VARCHAR2 DEFAULT NULL,
toDest2          IN  VARCHAR2 DEFAULT NULL,
toDest3          IN  VARCHAR2 DEFAULT NULL,
toDest4          IN  VARCHAR2 DEFAULT NULL);
TBD
 
GETBACKUPPIECE
Undocumented

Overload 1
dbms_rcvman.getBackupPiece(
bpRec       OUT NOCOPY bpRec_t,
closeCursor IN  BOOLEAN DEFAULT FALSE);
TBD
Overload 2 dbms_rcvman.getBackupPiece(
recid      OUT NUMBER,
stamp      OUT NUMBER,
bpkey      OUT NUMBER,
set_stamp  OUT NUMBER,
set_count  OUT NUMBER,
piece#     OUT NUMBER,
copy#      OUT NUMBER,
status     OUT VARCHAR2,
completion OUT DATE,
handle     OUT VARCHAR2);
Deprecated as of 8.1.6
Overload 3 dbms_rcvman.getBackupPiece(
recid     OUT NUMBER,
stamp     OUT NUMBER,
set_stamp OUT NUMBER,
set_count OUT NUMBER,
piece#    OUT NUMBER,
handle    OUT VARCHAR2);
Deprecated as of 8.1
 
GETBSBACKUPHISTORY
Retrieve BackupSet backup history dbms_rcvman.getBSBackupHistory(
backedUpDev IN  VARCHAR2,
first       IN  BOOLEAN,
set_stamp   IN  NUMBER DEFAULT NULL,
set_count   IN  NUMBER DEFAULT NULL,
bhistoryRec OUT NOCOPY bhistoryRec_t,
doingCmd    IN  VARCHAR2 DEFAULT NULL,
keepTag     IN  VARCHAR2 DEFAULT NULL,
toDest1     IN  VARCHAR2 DEFAULT NULL,
toDest2     IN  VARCHAR2 DEFAULT NULL,
toDest3     IN  VARCHAR2 DEFAULT NULL,
toDest4     IN  VARCHAR2 DEFAULT NULL);
TBD
 
GETCHECKPOINT
Returns the highest recovery catalog checkpoint SCN for FULL checkpoints

Overload 1
dbms_rcvman.getCheckpoint(scn OUT NUMBER, seq OUT NUMBER);
DECLARE
 vscn NUMBER;
 vseq NUMBER;
BEGIN
  dbms_rcvman.getCheckpoint(vscn, vseq);
  dbms_output.put_line(vscn);
  dbms_output.put_line(vseq);
END;
/
This version of getCheckpoint is only used internally by dbms_rcvcat.cleanupCKP, to find  rows that can't be deleted from ckp

Overload 2
dbms_rcvman.getCheckpoint(
scn       OUT NUMBER,
seq       OUT NUMBER,
ckp_key_1 OUT NUMBER,
ckp_key_2 OUT NUMBER);
DECLARE
 vscn NUMBER;
 vseq NUMBER;
 key1 NUMBER;
 key2 NUMBER;
BEGIN
  dbms_rcvman.getCheckpoint(vscn, vseq, key1, key2);
  dbms_output.put_line(vscn);
  dbms_output.put_line(vseq);
  dbms_output.put_line(key1);
  dbms_output.put_line(key2);
END;
/
 
GETCLONENAME
TSPITR dbms_rcvman.getCloneName(
fno    IN NUMBER,
crescn IN NUMBER,
pluscn IN NUMBER DEFAULT 0)
RETURN VARCHAR2;
TBD
 
GETCONFIG
Undocumented RMAN Configuration dbms_rcvman.getConfig(
conf#    OUT NUMBER,
name  IN OUT VARCHAR2,
value IN OUT VARCHAR2,
first IN     BOOLEAN);
DECLARE
 vcf  NUMBER;
 vnm  VARCHAR2(30);
 vval VARCHAR2(50);
BEGIN
  dbms_rcvman.getConfig(vcf, vnm, vval, TRUE);
END;
/
 
GETCONTROLFILEBACKUP
Returns of list of control file backups and the NUMBER of list entries dbms_rcvman.getControlfileBackup(rcvRec OUT NOCOPY rcvRec_t) RETURN NUMBER;
TBD
 
GETCONTROLFILECOPY
Undocumented
Overload 1
dbms_rcvman.getControlFileCopy(rcvRec IN OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.getControlFileCopy(
recid      OUT NUMBER,
stamp      OUT NUMBER,
reset_scn  OUT NUMBER,
ckp_scn    OUT NUMBER,
block_size OUT NUMBER);
Deprecated as of 8.1.6
 
GETCOPYOFDATAFILE
Copies the latest available datafilecopy for all translated datafiles

Overload 1
dbms_rcvman.getCopyofDatafile(
first         IN  BOOLEAN,        -- TRUE if this is the first time called
itag          IN  VARCHAR2,       -- tag that the copy should have or NULL
fno           OUT NUMBER,         -- datafile number
crescn        OUT NUMBER,         -- creation scn of the datafile
rlogscn       OUT NUMBER,         -- resetlogs scn of the datafile
rlgtime       OUT DATE,           -- resetlogs time of the datafile
recid         OUT BINARY_INTEGER, -- recid of the latest datafilecopy
stamp         OUT BINARY_INTEGER, -- stamp of the latest datafilecopy
name          OUT VARCHAR2,       -- name of the datafilecopy
otag          OUT VARCHAR2,       -- tag of the datafilecopy
status        OUT VARCHAR2,       -- status of the datafilecopy
nblocks       OUT BINARY_INTEGER, -- number of blocks of datafilecopy
bsz           OUT BINARY_INTEGER, -- blocksize of the datafilecopy
ctime         OUT DATE,           -- creation time of the datafilecopy
toscn         OUT NUMBER,         -- checkpoint scn of the datafilecopy
totime        OUT DATE,           -- checkpoint time of the datafilecopy
pluggedRonly  OUT BINARY_INTEGER, -- 1 for read-only. Otherwise, 0
pluginSCN     OUT NUMBER,         -- plugin scn
pluginRlgSCN  OUT NUMBER,         -- resetlogs when datafile was plugged
pluginRlgTime OUT DATE);          -- resetlog time when df was plugged
TBD
Overload 2 dbms_rcvman.getCopyofDatafile(
dfNUMBER      IN     NUMBER,         -- datafile NUMBER
itag          IN     VARCHAR2,       -- tag that the copy should have or NULL
crescn        IN OUT NUMBER,         -- creation scn of the datafile
rlogscn       IN OUT NUMBER,         -- resetlogs scn of the datafile
rlgtime       IN OUT DATE,           -- resetlogs time of the datafile
recid            OUT BINARY_INTEGER, -- recid of the latest datafilecopy
stamp            OUT BINARY_INTEGER, -- stamp of the latest datafilecopy
name             OUT VARCHAR2,       -- name of the datafilecopy
otag             OUT VARCHAR2,       -- tag of the datafilecopy
status           OUT VARCHAR2,       -- status of the datafilecopy
nblocks          OUT BINARY_INTEGER, -- NUMBER of blocks of datafilecopy
bsz              OUT BINARY_INTEGER, -- blocksize of the datafilecopy
ctime            OUT DATE,           -- creation time of the datafilecopy
toscn            OUT NUMBER,         -- checkpoint scn of the datafilecopy
totime           OUT DATE,           -- checkpoint time of the datafilecopy
pluggedRonly     OUT BINARY_INTEGER, -- 1 for read-only. Otherwise, 0
pluginSCN     IN     NUMBER);        -- plugin scn
TBD
Overload 3 dbms_rcvman.getCopyofDatafile(
dfNUMBER IN     NUMBER,         -- datafile NUMBER
itag     IN     VARCHAR2,       -- tag that the copy should have or NULL
crescn   IN     NUMBER,         -- creation scn of the datafile
rlogscn  IN     NUMBER,         -- resetlogs scn of the datafile
rlgtime  IN     DATE,           -- resetlogs time of the datafile
recid       OUT BINARY_INTEGER, -- recid of the latest datafilecopy
stamp       OUT BINARY_INTEGER, -- stamp of the latest datafilecopy
name        OUT VARCHAR2,       -- name of the datafilecopy
otag        OUT VARCHAR2,       -- tag of the datafilecopy
status      OUT VARCHAR2,       -- status of the datafilecopy
nblocks     OUT BINARY_INTEGER, -- NUMBER of blocks of the datafilecopy
bsz         OUT BINARY_INTEGER, -- blocksize of the datafilecopy
ctime       OUT DATE,           -- creation time of the datafilecopy
toscn       OUT NUMBER,         -- checkpoint scn of the datafilecopy
totime      OUT DATE);          -- checkpoint time of the datafilecopy
Deprecated as of 11g
 
GETCURRENTINCARNATION
Retrieve Current Database Incarnation dbms_rcvman.getCurrentIncarnation(
db_id      IN  NUMBER,
reset_scn  OUT NUMBER,
reset_time OUT DATE);
set serveroutput on

exec dbms_rcvman.setDatabase(NULL, NULL, NULL, NULL, 2497516142);

DECLARE
 rscn NUMBER;
 rdat DATE;
BEGIN
  dbms_rcvman.getCurrentIncarnation(2497516142, rscn, rdat);
  dbms_output.put_line(rscn);
  dbms_output.put_line(rdat);
END;
/
 
GETDATAFILE
Retrieves the datafile numbers, one at a time until null is returned

Overload 1
dbms_rcvman.getdatafile(
dfRec     OUT NOCOPY dfRec_t,
oldClient IN         BOOLEAN DEFAULT FALSE);
TBD
Overload 2 dbms_rcvman.getDataFile(
file#                 OUT NUMBER,
crescn                OUT NUMBER,
creation_time         OUT DATE,
fname                 OUT VARCHAR2,
ts_name               OUT VARCHAR2,
status                OUT NUMBER,
blksize               OUT NUMBER,
kbytes                OUT NUMBER,
blocks                OUT NUMBER,
unrecoverable_change# OUT NUMBER,
stop_change#          OUT NUMBER,
read_only             OUT NUMBER);
Deprecated as of 8.1.6
 
GETDATAFILECOPY
Undocumented

Overload 1
dbms_rcvman.getDataFileCopy(
rcvRec      OUT NOCOPY rcvRec_t,
closeCursor IN  BOOLEAN DEFAULT FALSE);
TBD
Overload 2 dbms_rcvman.getDataFileCopy(
recid      OUT NUMBER,
stamp      OUT NUMBER,
file#      OUT NUMBER,
fname      OUT VARCHAR2,
reset_scn  OUT NUMBER,
create_scn OUT NUMBER,
ckp_scn    OUT NUMBER,
block_size OUT NUMBER,
blocks     OUT NUMBER);
Deprecated as of 8.1.6
 
GETDBUNIQUENAME
Return the db_unique_name associated with the db_id dbms_rcvman.getdbuniquename(db_id IN NUMBER) RETURN VARCHAR2;
SELECT dbid FROM v$database;

SELECT dbms_rcvman.getdbuniquename(1746737380)
FROM dual;
 
GETDCBACKUPHISTORY
Retrieve DC backup history dbms_rcvman.getDCBackupHistory(
backedUpDev IN  VARCHAR2,
first       IN  BOOLEAN,
bhistoryRec OUT NOCOPY bhistoryRec_t,
doingCmd    IN  VARCHAR2 DEFAULT NULL,
keepTag     IN  VARCHAR2 DEFAULT NULL,
toDest1     IN  VARCHAR2 DEFAULT NULL,
toDest2     IN  VARCHAR2 DEFAULT NULL,
toDest3     IN  VARCHAR2 DEFAULT NULL,
toDest4     IN  VARCHAR2 DEFAULT NULL);
TBD
 
GETDFBACKUPHISTORY
Retrieve Data File Backup History dbms_rcvman.getDFBackupHistory(
backedUpDev   IN  VARCHAR2,
first         IN  BOOLEAN,
bhistoryRec   OUT NOCOPY bhistoryRec_t,
recentbackup  IN  BOOLEAN  DEFAULT FALSE, -- get no: recent backups
doingCmd      IN  VARCHAR2 DEFAULT NULL,
keepTag       IN  VARCHAR2 DEFAULT NULL,
toDest1       IN  VARCHAR2 DEFAULT NULL,
toDest2       IN  VARCHAR2 DEFAULT NULL,
toDest3       IN  VARCHAR2 DEFAULT NULL,
toDest4       IN  VARCHAR2 DEFAULT NULL);
TBD
 
GETDROPOSFILES
Undocumented dbms_rcvman.getdropOSFiles(
first       IN  BOOLEAN,
agedFileRec OUT NOCOPY agedFileRec_t);
TBD
 
GETDROPSCN (new 12.1)
Finds the drop_scn for a datafile dbms_rcvman.getDropSCN(
dfNum        IN  NUMBER,
creScn       IN  NUMBER,
creTime      IN  DATE,
plugScn      IN  NUMBER,
foreignDbId  IN  NUMBER,
dropScn      OUT NUMBER,
dropTime     OUT DATE,
dropDbIncKey OUT NUMBER,
dropRlgScn   OUT NUMBER,
dropRlgTime  OUT DATE)
RETURN BOOLEAN;
TBD
 
GETENCRYPTTSCOUNT
Returns the count of encrypted tablespaces dbms_rcvman.getEncryptTSCount RETURN BINARY_INTEGER;
SELECT dbms_rcvman.getEncryptTSCount
FROM dual;
 
GETFAILURE
Retrieve the failure list whose cursor is opened by the translateFailure procedure dbms_rcvman.failureRec OUT NOCOPY failureRec_t);
TBD
 
GETINCARNATIONKEY
Return the incarnation key to which the untilscn belongs if the untilscn is in one of its parent. 0 to indicate if the untilscn is in current incarnation. dbms_rcvman.getIncarnationKey(untilSCN IN NUMBER) RETURN NUMBER;
SELECT current_scn FROM v$database;

SELECT dbms_rcvman.getIncarnationKey(64000000)
FROM dual;
 
GETINCREMENTALSCN
Returns the starting scn for an incremental backup

Overload 1
dbms_rcvman.getIncrementalScn(
file#      IN NUMBER,
create_scn IN NUMBER,
reset_scn  IN NUMBER,
reset_time IN DATE,
incr_level IN NUMBER,
cumulative IN NUMBER,
sourcemask IN NUMBER   DEFAULT NULL,
tag        IN VARCHAR2 DEFAULT NULL,
pluginSCN  IN NUMBER   DEFAULT 0)
RETURN NUMBER;
TBD
This is an improved version of Overload 1

Overload 2
dbms_rcvman.getIncrementalScn(
first      IN  BOOLEAN, -- open the cursor if this is TRUE
file#      IN  NUMBER,
create_scn IN  NUMBER,
reset_scn  IN  NUMBER,
reset_time IN  DATE,
incr_level IN  NUMBER,
cumulative IN  NUMBER,
rcvRec     OUT NOCOPY rcvRec_t,
sourcemask IN  NUMBER   DEFAULT NULL,
tag        IN  VARCHAR2 DEFAULT NULL,
pluginSCN  IN  NUMBER   DEFAULT 0,
keep       IN  BOOLEAN  DEFAULT FALSE);
TBD
 
GETMANUALREPAIR
Called to retrieve the manual repair message whose cursor is opened by the translateManualRepair procedure dbms_rcvman.getManualRepair(mandatory OUT VARCHAR2) RETURN VARCHAR2;
set serveroutput on

DECLARE
 mand VARCHAR2(100);
 retv VARCHAR2(100);
BEGIN
  dbms_rcvman.translateManualRepair(8075);
  retv := dbms_rcvman.getManualRepair(mand);
  dbms_output.put_line(retv);
  dbms_output.put_line(mand);
END;
/
 
GETMAXCOPYNO
Returns the maximum copy number dbms_rcvman.getMaxCopyNo(bsstamp IN NUMBER, bscount IN NUMBER)
RETURN NUMBER;
TBD
 
GETMAXREDOSCN (new 12.1)
Finds out the maximum scn of the redo logs dbms_rcvman.getMaxRedoSCN(
maxScn      OUT NUMBER,
maxTime     OUT DATE,
maxDbIncKey OUT NUMBER,
maxRlgScn   OUT NUMBER,
maxRlgTime  OUT DATE,
isOrs       IN  NUMBER)
RETURN BOOLEAN;
TBD
 
GETMAXSCN
Obtain maximum scn from archived logs registered in the catalog

Interestingly this function is commented as obsolete in 11.2

Overload 1
dbms_rcvman.getMaxSCN RETURN NUMBER;
SELECT dbid FROM v$database;

exec dbms_rcvman.setDatabase('ORABASE', 940976, TO_DATE('11-APR-2013 16:05:25');

SELECT dbms_rcvman.getMaxSCN
FROM dual;
Overload 2 dbms_rcvman.getMaxSCN(logmaxnt OUT DATE) RETURN NUMBER;
SELECT dbid FROM v$database;

exec dbms_rcvman.setDatabase('ORABASE', 940976, TO_DATE('11-APR-2013 16:05:25');

set serveroutput on

DECLARE
 maxdt DATE;
 retvl NUMBER;
BEGIN
  retvl := dbms_rcvman.getMaxSCN(maxdt);
  dbms_output.put_line(maxdt);
END;
/
 
GETNEXTAVAILABLESCN (new 12.1)
Finds the next available SCN from archived log registered in the catalog
after fromScn. Returns FALSE if no SCN found else returns TRUE
dbms_rcvman.getNextAvailableSCN(
fromScn          IN  NUMBER,
nextAvailableSCN OUT NUMBER,
isOrs            IN  NUMBER)
RETURN BOOLEAN;
TBD
 
GETOFFLINERANGECOPY
Undocumented
Overload 1
dbms_rcvman.getOfflineRangeCopy(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.getOfflineRangeCopy RETURN VARCHAR2;
Deprecated as of 8.1.6
 
GETONLINELOG
Undocumented dbms_rcvman.getOnlineLog(
fname   OUT VARCHAR2,
thread# OUT NUMBER,
group#  OUT NUMBER);
set serveroutput on

DECLARE
 fn NUMBER;
 th NUMBER;
 gr NUMBER;
BEGIN
  dbms_rcvman.getOnlineLog(fn, th, gr);
  dbms_output.put_line(fn);
  dbms_output.put_line(th);
  dbms_output.put_line(gr);
END;
/
 
GETPACKAGEVERSION
Returns the package version dbms_rcvman.getPackageVersion RETURN VARCHAR2;
SELECT dbms_rcvman.getPackageVersion
FROM dual;
 
GETPARENTINCARNATION
Returns the parent incarnation. If resetlogs_change# is NULL on input, then the current incarnation is returned. Returns TRUE if a row was returned, otherwise returns FALSE. dbms_rcvman.getParentIncarnation(
resetlogs_change# IN OUT NUMBER,
resetlogs_time    IN OUT DATE)
RETURN NUMBER;
TBD
 
GETPRIMARYDFNAME
Undocumented dbms_rcvman.getPrimaryDfName(fno IN NUMBER) RETURN VARCHAR2;
TBD
 
GETPROXYCOPY
Undocumented

Overload 1
dbms_rcvman.getProxyCopy(
rcvRec      OUT NOCOPY rcvRec_t,
closeCursor IN  BOOLEAN DEFAULT FALSE);
TBD
Overload 2 dbms_rcvman.getProxyCopy(
recid  OUT NUMBER,
stamp  OUT NUMBER,
handle OUT VARCHAR2);
Deprecated as of 8.1.6
 
GETRCVREC
This is a cover function for all procedures/functions that return a rcvRec_t. It routes the call to the correct procedure dbms_rcvman.getRcvRec(
funCode   IN  NUMBER,
rcvRec    OUT NOCOPY rcvRec_t,
callAgain OUT NUMBER)
RETURN NUMBER;
TBD
 
GETRECOVERYACTION
Undocumented
Overload 1
dbms_rcvman.getRecoveryAction(action OUT NOCOPY rcvRec_t) RETURN BINARY_INTEGER;
TBD
Overload 2 dbms_rcvman.getRecoveryAction(
kind      OUT NUMBER,
set_stamp OUT NUMBER,
set_count OUT NUMBER,
recid     OUT NUMBER,
stamp     OUT NUMBER,
fname     OUT VARCHAR2,
blocksize OUT NUMBER,
blocks    OUT NUMBER,
devtype   OUT VARCHAR2,
from_scn  OUT NUMBER,
to_scn    OUT NUMBER,
to_time   OUT DATE,
rlgscn    OUT NUMBER,
rlgtime   OUT DATE,
cfcretime OUT DATE,
dbinc_key OUT NUMBER)
RETURN BINARY_INTEGER;
Deprecated as of 8.1.6
 
GETREDOLOGDELETIONPOLICY
Returns the redo log deletion policy dbms_rcvman.getRedoLogDeletionPolicy(policy OUT VARCHAR2);
set serveroutput on

DECLARE
 po VARCHAR2(100);
BEGIN
  dbms_rcvman.getRedoLogDeletionPolicy(po);
  dbms_output.put_line(po);
END;
/
 
GETREPAIR
Retrieves the repair list whose cursor is opened by translateRepair. Until it returns a no-data-found exception, the function is called again and again to retrieve all the options. dbms_rcvman.getRepair(repairRec OUT NOCOPY repairRec_t);
DECLARE
 repairArray dbms_rcvman.repairRec_t;
BEGIN
  -- translateRepair is called to open the cursor to retrieve the repair list
  dbms_rcvman.translateRepair(8075);
  dbms_rcvman.getRepair(repairArray);
END;
/
 
GETREPAIROPTION
Retrieve the repair option list for the cursor opened by translateRepairOption dbms_rcvman.getRepairOption(repairOptionRec OUT NOCOPY repairOptionRec_t);
DECLARE
 repairArray dbms_rcvman.repairOptionRec_t;
BEGIN
  -- translateRepairOption is called to open the cursor to the repair list
  dbms_rcvman.translateRepairOption(8075);
  dbms_rcvman.getRepairOption(repairArray);
END;
/
 
GETREPAIRPARMS
Retrieve the repair parameters for the cursor opened by translateRepairParms dbms_rcvman.getRepairParms(repairParmsRec OUT NOCOPY repairParmsRec_t);
DECLARE
 repairArray dbms_rcvman.repairParmsRec_t;
BEGIN
  -- translateRepairParms is called to open the cursor to retrieve the repair parameters
  dbms_rcvman.translateRepairParms(8075);
  dbms_rcvman.getRepairParms(repairArray);
END;
/
 
GETREPAIRSCRIPTNAME
Retrieves the repair script filename from v$ir_repair and description dbms_rcvman.getRepairScriptName(repairId IN NUMBER, description OUT VARCHAR2)
RETURN VARCHAR2;
SELECT repair_id
FROM v$ir_repair;

set serveroutput on

DECLARE
 retv VARCHAR2(100);
 desr VARCHAR2(100);
BEGIN
  retv := dbms_rcvman.getRepairScriptName(8075, desr);
  dbms_output.put_line(retv);
  dbms_output.put_line(desr);
END;
/
 
GETREPAIRSTEP
Retrieves the repair steps whose cursor is opened by the translateRepairStep procedure. This function is called until it returns a NO_DATA_FOUND exception. dbms_rcvman.getRepairStep(repairStepRec OUT NOCOPY repairStepRec_t);
exec dbms_rcvman.translateRepairStep(0);

DECLARE
 repairRec dbms_rcvman.repairStepRec_t;
BEGIN
  dbms_rcvman.getRepairStep(repairRec);
  dbms_output.put_line(repairRec.repairscript); 
END;
/
 
GETREQUIREDSCN
Calculate the lowest gap for all destinations. Calculate the highest scn available on all valid standby destinations. If no gap, return the high scn, otherwise return the gap. If streams is true consider streams also when computing remote destination required SCN. dbms_rcvman.getRequiredSCN(
reqscn  OUT NUMBER,
rlgscn  OUT NUMBER,
streams IN  NUMBER DEFAULT 0,
alldest IN  NUMBER DEFAULT 0);
TBD
 
GETRESTOREPOINT
Given a name return information about the restore point dbms_rcvman.getRestorePoint(
name       IN  VARCHAR2,
rlgscn     OUT NUMBER,
rlgtime    OUT DATE,
scn        OUT NUMBER,
guaranteed OUT NUMBER);
set serveroutput on

CREATE RESTORE POINT before_damage;

DECLARE
 rlgscn NUMBER;
 rlgtim DATE;
 scn    NUMBER;
 guar   NUMBER;
BEGIN
  dbms_rcvman.getRestorePoint('BEFORE_DAMAGE', rlgscn, rlgtim, scn, guar);
  dbms_output.put_line(rlgscn);
  dbms_output.put_line(rlgtim);
  dbms_output.put_line(scn);
  dbms_output.put_line(guar);
END;
/

DROP RESTORE POINT before_damage;
 
GETRESTORERANGESET (new 12.1)
Finds the set of restore ranges of a database dbms_rcvman.getRestoreRangeSet(
restoreRangeTab OUT restoreRangeTab_t,
opCode          IN  VARCHAR2,
db_id           IN  NUMBER)
RETURN BOOLEAN;
TBD
 
GETRETENTIONPOLICY
Retrieve currently configured retention policy (Deprecated) dbms_rcvman.getRetentionPolicy(recovery_window OUT NUMBER, redundancy OUT NUMBER);
set serveroutput on

DECLARE
 rw NUMBER;
 rd NUMBER;
BEGIN
  dbms_rcvman.getRetentionPolicy(rw, rd);
  dbms_output.put_line(rw);
  dbms_output.put_line(rd);
END;
/
 
GETSCNFORAPPLIEDPOLICY
Must be called after setRedoLogDeletionPolicy call. The function is intended to compute the SCN above which all archivelogs are kept for TO APPLIED|SHIPPED policy. dbms_rcvman.getSCNForAppliedPolicy(minscn OUT NUMBER, rlgscn OUT NUMBER);
set serveroutput on

DECLARE
 mscn NUMBER;
 rscn NUMBER;
BEGIN
  dbms_rcvman.setRedoLogDeletionPolicy('UW Policy', dbms_rcvman.TRUE#);
  dbms_rcvman.getSCNForAppliedPolicy(mscn, rscn);
  dbms_output.put_line(mscn);
  dbms_output.put_line(rscn);
END;
/
 
GETSITEKEY
Retrieve the site key for given db_unique_name dbms_rcvman.getSiteKey(db_unique_name IN VARCHAR2) RETURN NUMBER;
SELECT name, value
FROM v$parameter
WHERE name LIKE '%unique%';

DECLARE
 dbun NUMBER;
BEGIN
  dbun := dbms_rcvman.getSiteKey('oradata');
  dbms_output.put_line(dbun); 
END;
/
 
GETSITENAME
Retrieve site name for site_key dbms_rcvman.getsitename(site_key IN NUMBER) RETURN VARCHAR2;
TBD
 
GETSPACERECL
Returns space reclaimable in bytes for files in reclaimable record table ceilAsm - when TRUE, ceil ASM file size in MB dbms_rcvman.getSpaceRecl(ceilAsm IN BINARY_INTEGER DEFAULT 0) RETURN NUMBER;
SELECT dbms_rcvman.getSpaceRecl(0) FROM dual;
 
GETSPFILEBACKUP
Redundancy determines the number of redundant copies to fetch if findSpfileBackup wasn't called earlier dbms_rcvman.getSPFileBackup(
rcvRec     OUT NOCOPY rcvRec_t,
redundancy IN  NUMBER default NULL,
rmanCmd    IN  NUMBER default unknownCmd_t)
RETURN NUMBER;
TBD
 
GETTEMPFILE
Fetch the cursor opened by translateTempfiles and return a row one at a time until all rows are returned. Signal ORA-1403 (no-data-found) when there are no more rows to return. dbms_rcvman.getTempFile(tfRec OUT NOCOPY tfRec_t);
DECLARE
 retArr dbms_rcvman.tfRec_t;
BEGIN
  dbms_rcvman.getTempFile(retArr);
END;
/
 
GETUNTILSCN
Undocumented dbms_rcvman.getUntilSCN RETURN NUMBER;
SELECT dbms_rcvman.getUntilSCN
FROM dual;
 
GETUNTILTIME
Undocumented dbms_rcvman.getUntilTime RETURN DATE;
exec dbms_rcvman.setUntilTime(SYSDATE-1/24);

SELECT dbms_rcvman.getUntilTime
FROM dual;
 
GETVALIDBACKUPSET
Attempts to retrieve a valid backup set. 1 means a record was found, 0 means NO_DATA_FOUND. dbms_rcvman.getValidBackupSet(
validBackupSetRec      OUT NOCOPY validBackupSetRec_t,
checkDeviceIsAllocated IN  NUMBER DEFAULT FALSE#)
RETURN NUMBER;
TBD
 
INITIALIZE
This is a vestigal function that was released to customers in 8.1.3 Beta. It is no longer called, and is no longer needed, but must still be herebecause this version of the package may be called by an 8.1.3 RMAN executable. dbms_rcvman.initialize(rman_vsn IN NUMBER);
Deprecated since 8.1.3
 
ISARCHIVEDLOGMISSING
Check if there a log is missing between fromscn to untilscn. Return TRUE if a log is missing. Otherwise, FALSE dbms_rcvman.isArchivedLogMissing(fromSCN IN NUMBER, untilSCN IN NUMBER)
RETURN NUMBER;
SELECT current_scn
FROM v$database;

SELECT dbms_rcvman.isArchivedLogMissing(50000000, 6000000)
FROM dual;
 
ISBACKUPTYPEMATCH
Undocumented dbms_rcvman.isBackupTypeMatch(btype IN VARCHAR2, mask IN BINARY_INTEGER)
RETURN NUMBER;
TBD
 
ISBSRECCACHEMATCH
Undocumented dbms_rcvman.isBSRecCacheMatch(
key        IN NUMBER,
deviceType IN VARCHAR2,
tag        IN VARCHAR2,
status     IN VARCHAR2)
RETURN NUMBER;
TBD
 
ISDEVICETYPEALLOCATED
Undocumented dbms_rcvman.isDeviceTypeAllocated(deviceType IN VARCHAR2) RETURN NUMBER;
TBD
 
ISINFAILURELIST
Called to find out whether the parent_id or failureid is part of getFailureNumList or getFailureExclude list. Return TRUE# if present in failure_list. Otherwise, return FALSE#. dbms_rcvman.isInFailureList(
parentId    IN NUMBER,
failureId   IN NUMBER,
for_exclude IN BINARY_INTEGER)
RETURN NUMBER;
TBD
 
ISPDBSCNORPHAN (new 12.1)
Returns TRUE# if the untilSCN is in orphan branch of PDB. Otherwise,
FALSE#
dbms_rcvman.isPDBSCNOrphan(
untilSCN IN NUMBER,
pdbId    IN NUMBER)
RETURN BOOLEAN;
TBD
 
ISRECLRECID
Is this record reclaimable? dbms_rcvman.isreclrecid(rectype IN BINARY_INTEGER, recid IN NUMBER)
RETURN NUMBER;
TBD
 
ISSTATUSMATCH
Undocumented dbms_rcvman.isstatusmatch(status IN VARCHAR2, mask IN NUMBER) RETURN NUMBER;
TBD
 
ISTRANSLATEDDBID
Is this dbid translated by RMAN? Returns TRUE# if translated. Otherwise, FALSE# dbms_rcvman.isTranslatedDbid(dbid IN NUMBER) RETURN NUMBER;
See SETDBIDTRANSCLAUSE Demo Below
 
ISTRANSLATEDFNO
Is this file translated by RMAN? Returns TRUE# if translated. Otherwise, FALSE# dbms_rcvman.isTranslatedfno(fno IN NUMBER) RETURN NUMBER;
SELECT file_name, relative_fno
FROM dba_data_files;

SELECT dbms_rcvman.isTranslatedFNo(6)
FROM dual;
 
ISTRANSLATEDPDBID (new 12.1)
Is this pdbid translated by RMAN?. Returns TRUE# if translated. Otherwise, FALSE#. dbms_rcvman.isTranslatedPDBID(pdbId IN NUMBER) RETURN NUMBER;
SELECT name, dbid FROM v$pdbs;

SELECT dbms_rcvman.isTranslatedPDBID(1354451219)
FROM dual;
 
LISTBACKUP
Lists (obsolete) backups (backup sets, pieces, copies, proxy copies, and archived logs dbms_rcvman.listbackup(
lbRecOut         OUT NOCOPY lbRec_t,
firstCall     IN            BOOLEAN,
only_obsolete IN            BOOLEAN,
redundancy    IN            NUMBER,
piped_call    IN            BOOLEAN,
lbCursor      IN OUT NOCOPY lbCursor_t,
lbState       IN OUT NOCOPY lbState_t,
extRlKeepSCN  IN            NUMBER DEFAULT NULL)
RETURN BOOLEAN;
TBD
 
LISTGETARCHIVEDLOGBACKUP
Undocumented

Overload 1
dbms_rcvman.listGetArchivedLogBackup(rcvRec OUT NOCOPY rcvRec_t);
DECLARE
 retArr dbms_rcvman.rcvRec_t;
BEGIN
  dbms_rcvman.listGetArchivedLogBackup(retArr);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 22953
ORA-06512: at line 4
Overload 2 dbms_rcvman.listGetArchivedLogBackup(
bs_key          OUT NUMBER,
completion_time OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1
Overload 3 dbms_rcvman.listGetArchivedLogBackup(
bs_key        OUT NUMBER,
thread#       OUT NUMBER,
sequence#     OUT NUMBER,
first_change# OUT NUMBER,
next_change#  OUT NUMBER,
first_time    OUT DATE,
next_time     OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETARCHIVEDLOGCOPY
Returns an aray of Archived Logfile Copies
Overload 1
dbms_rcvman.listGetArchivedLogCopy(rcvRec OUT NOCOPY rcvRec_t);
DECLARE
 retArr dbms_rcvman.rcvRec_t;
BEGIN
  dbms_rcvman.listGetArchivedLogCopy(retArr);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 22544
ORA-06512: at line 4
Overload 2 dbms_rcvman.listGetArchivedLogCopy(
al_key          OUT NUMBER,
status          OUT VARCHAR2,
fname           OUT VARCHAR2,
completion_time OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETBACKUPSETFILES
Returns an array of backupset files dbms_rcvman.listGetBackupsetFiles(rcvRec OUT NOCOPY rcvRec_t);
DECLARE
 retArr dbms_rcvman.rcvRec_t;
BEGIN
  dbms_rcvman.listGetBackupsetFiles(retArr);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 23087
ORA-06512: at line 4
 
LISTGETCONTROLFILEBACKUP
Returns an array of Control File backups
Overload 1
dbms_rcvman.listGetControlfileBackup(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.listGetControlfileBackup(
bskey   OUT NUMBER,
ckpscn  OUT NUMBER,
ckptime OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETCONTROLFILECOPY
Returns an array of Control File copies
Overload 1
dbms_rcvman.listGetControlfileCopy(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.listGetControlfileCopy(
bcfkey     OUT NUMBER,
ckpscn     OUT NUMBER,
ckptime    OUT DATE,
status     OUT VARCHAR2,
completion OUT DATE,
fname      OUT VARCHAR2)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETDATAFILEBACKUP
Returns an array of Data File backups
Overload 1
dbms_rcvman.listGetDataFileBackup(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.listGetDataFileBackup(
bs_key             OUT NUMBER,
backup_type        OUT VARCHAR2,
incremental_level  OUT NUMBER,
completion_time    OUT DATE,
checkpoint_change# OUT NUMBER,
checkpoint_time    OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETDATAFILECOPY
Returns an array of Data File copies
Overload 1
dbms_rcvman.listGetDataFileCopy(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.listGetDataFileCopy(
cdf_key            OUT NUMBER,
status             OUT VARCHAR2,
fname              OUT VARCHAR2,
completion_time    OUT DATE,
checkpoint_change# OUT NUMBER,
checkpoint_time    OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETDBINCARNATION
Returns an array of Database incarnations

Overload 1
dbms_rcvman.listGetDBIncarnation(
db_key            OUT NUMBER,
dbinc_key         OUT NUMBER,
db_name           OUT VARCHAR2,
db_id             OUT NUMBER,
current_inc       OUT VARCHAR2,
resetlogs_change# OUT NUMBER,
resetlogs_time    OUT DATE,
dbinc_status      OUT VARCHAR2)
RETURN NUMBER;
DECLARE
 dkey       NUMBER;
 ikey       NUMBER;
 dname      VARCHAR2(30);
 dbid       NUMBER;
 cur_inc    VARCHAR2(30);
 rlc_num    NUMBER;
 rl_time    DATE;
 inc_status VARCHAR2(30);
 retVal     NUMBER;
BEGIN
  retVal := dbms_rcvman.listGetDBIncarnation(dkey, ikey, dname, dbid, cur_inc, rlc_num, rl_time, inc_status);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 23393
ORA-06512: at line 12
Overload 2 dbms_rcvman.listGetDBIncarnation(
db_key            OUT NUMBER,
dbinc_key         OUT NUMBER,
db_name           OUT VARCHAR2,
db_id             OUT NUMBER,
current_inc       OUT VARCHAR2,
resetlogs_change# OUT NUMBER,
resetlogs_time    OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETDBSITE
Returns an array of Database sites dbms_rcvman.listGetDBSite(
db_key         OUT NUMBER,
db_id          OUT NUMBER,
db_name        OUT VARCHAR2,
db_role        OUT VARCHAR2,
db_unique_name OUT VARCHAR2)
RETURN NUMBER;
TBD
 
LISTGETPROXYARCHIVEDLOG
Returns an array of proxy Archived Logs dbms_rcvman.listGetProxyArchivedLog(rcvRec OUT NOCOPY rcvRec_t);
TBD
 
LISTGETPROXYDATAFILE
Returns an array of proxy Data Files
Overload 1
dbms_rcvman.listGetProxyDataFile(rcvRec OUT NOCOPY rcvRec_t);
TBD
Overload 2 dbms_rcvman.listGetProxyDataFile(
xdf_key            OUT NUMBER,
recid              OUT NUMBER,
stamp              OUT NUMBER,
status             OUT VARCHAR2,
handle             OUT VARCHAR2,
completion_time    OUT DATE,
checkpoint_change# OUT NUMBER,
checkpoint_time    OUT DATE)
RETURN NUMBER;
Deprecated as of 8.1.6
 
LISTGETRESTOREPOINT
Returns information about the current restore point dbms_rcvman.listGetRestorePoint(
name    OUT VARCHAR2,
scn     OUT NUMBER,
rsptime OUT DATE,
cretime OUT DATE,
rsptype OUT VARCHAR2);
TBD
 
LISTGETSPFILEBACKUP
Returns information about SPFILE backups dbms_rcvman.listGetSpfileBackup(rcvRec OUT NOCOPY rcvRec_t);
DECLARE
 spinfo dbms_rcvman.rcvRec_t;
BEGIN
  dbms_rcvman.listGetSpfileBackup(spinfo);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 22726
ORA-06512: at line 4
 
LISTGETTABLESPACE
Returns information about Tablespace backups dbms_rcvman.listGetTablespace(ts# OUT NUMBER, ts_name OUT VARCHAR2)
RETURN NUMBER;
set serveroutput on

DECLARE
 retv NUMBER;
 tsno NUMBER;
 tsnm user_tablespaces.tablespace_name%TYPE;
BEGIN
  retv := dbms_rcvman. listGetTablespace(tsno, tsnm);
  dbms_output.put_line(retv);
  dbms_output.put_line(tsno);
  dbms_output.put_line(tsnm);
END;
/
DECLARE
*
ERROR at line 1:
ORA-01001: invalid cursor
ORA-06512: at "SYS.DBMS_RCVMAN", line 23499
ORA-06512: at line 6
 
LISTROLLBACKSEGTABLESPACE
Returns information about tablespaces containing Rollback Segments dbms_rcvman.listRollbackSegTablespace;
exec dbms_rcvman.listRollbackSegTablespace;
 
LISTTRANSLATEARCHIVEDLOGBACKUP
List Archived Log backups

Overload 1
dbms_rcvman.listTranslateArchivedLogBackup(
thread#         IN NUMBER,
sequence#       IN NUMBER,
first_change#   IN NUMBER,
completedAfter  IN DATE DEFAULT NULL,
completedBefore IN DATE DEFAULT NULL,
statusMask      IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired);
8.0 and 8.1.6, but not 8.1.5
Overload 2 dbms_rcvman.listTranslateArchivedLogBackup(
thread#    IN NUMBER   DEFAULT NULL,
lowseq     IN NUMBER   DEFAULT NULL,
highseq    IN NUMBER   DEFAULT NULL,
lowscn     IN NUMBER   DEFAULT NULL,
highscn    IN NUMBER   DEFAULT NULL,
from_time  IN DATE     DEFAULT NULL,
until_time IN DATE     DEFAULT NULL,
pattern    IN VARCHAR2 DEFAULT NULL);
Deprecated as of 8.1.6, but used in 9.0
 
LISTTRANSLATEARCHIVEDLOGCOPY
Undocumented dbms_rcvman.listTranslateArchivedLogCopy(
thread#           IN NUMBER,
sequence#         IN NUMBER,
first_change#     IN NUMBER,
file_name_pattern IN VARCHAR2 DEFAULT NULL,
completedAfter    IN DATE     DEFAULT NULL,
completedBefore   IN DATE     DEFAULT NULL,
statusMask        IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired,
                     --8.0/8.1 defaults
needstby          IN NUMBER   DEFAULT NULL);
TBD
 
LISTTRANSLATEBACKUPSETFILES
Undocumented dbms_rcvman.listTranslateBackupSetFiles(bs_key IN NUMBER);
TBD
 
LISTTRANSLATECONTROLFILEBACKUP
Undocumented dbms_rcvman.listTranslateControlFileBackup(
tag             IN VARCHAR2,
completedAfter  IN DATE,
completedBefore IN DATE,
statusMask IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired,
           -- 8.0/8.1 defaults
autobackup      IN BINARY_INTEGER DEFAULT BScfile_all,
liststby        IN BINARY_INTEGER DEFAULT NULL);
TBD
 
LISTTRANSLATECONTROLFILECOPY
Undocumented dbms_rcvman.listTranslateControlFileCopy(
tag             IN VARCHAR2,
completedAfter  IN DATE,
completedBefore IN DATE,
statusMask      IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired,
liststby        IN BINARY_INTEGER DEFAULT NULL, -- default for 8.1
file_pattern    IN VARCHAR2       DEFAULT NULL);
TBD
 
LISTTRANSLATEDATAFILEBACKUP
Undocumented dbms_rcvman.listTranslateDataFileBackup(
file#            IN NUMBER,
creation_change# IN NUMBER,
tag              IN VARCHAR2 DEFAULT NULL,
completedAfter   IN DATE     DEFAULT NULL,
completedBefore  IN DATE     DEFAULT NULL,
statusMask       IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired,
                    -- 8.0/8.1 defaults
pluginSCN        IN NUMBER   DEFAULT 0);
TBD
 
LISTTRANSLATEDATAFILECOPY
Undocumented dbms_rcvman.listTranslateDataFileCopy(
file#             IN NUMBER,
creation_change#  IN NUMBER,
tag               IN VARCHAR2 DEFAULT NULL,
file_name_pattern IN VARCHAR2 DEFAULT NULL,
completedAfter    IN DATE DEFAULT NULL,
completedBefore   IN DATE DEFAULT NULL,
statusMask        IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable, -- default for 8.1
pluginSCN         IN NUMBER DEFAULT 0);
TBD
 
LISTTRANSLATEDBINCARNATION
Undocumented dbms_rcvman.listTranslateDBIncarnation(
db_name       IN VARCHAR2 DEFAULT NULL,
all_databases IN NUMBER   DEFAULT 0);
TBD
 
LISTTRANSLATEDBSITE
Undocumented dbms_rcvman.listTranslateDBSite(
db_name IN VARCHAR2       DEFAULT NULL,
alldbs  IN BINARY_INTEGER DEFAULT 1);
TBD
 
LISTTRANSLATEPROXYARCHIVEDLOG
Undocumented dbms_rcvman.listTranslateProxyArchivedLog(
thread#         IN NUMBER,
sequence#       IN NUMBER,
first_change#   IN NUMBER,
tag             IN VARCHAR2       DEFAULT NULL,
handle_pattern  IN VARCHAR2       DEFAULT NULL,
completedAfter  IN DATE           DEFAULT NULL,
completedBefore IN DATE           DEFAULT NULL,
statusMask      IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired);
TBD
 
LISTTRANSLATEPROXYDATAFILE
Undocumented dbms_rcvman.listTranslateProxyDataFile(
file#            IN NUMBER,
creation_change# IN NUMBER,
tag              IN VARCHAR2       DEFAULT NULL,
handle_pattern   IN VARCHAR2       DEFAULT NULL,
completedAfter   IN DATE           DEFAULT NULL,
completedBefore  IN DATE           DEFAULT NULL,
statusMask       IN BINARY_INTEGER DEFAULT BSavailable+BSunavailable+BSexpired,
liststby         IN BINARY_INTEGER DEFAULT NULL, -- default for 8.1
pluginSCN        IN NUMBER         DEFAULT 0);
TBD
 
LISTTRANSLATEPROXYDFRECID
Undocumented dbms_rcvman.listTranslateProxyDFRecID(
recid              IN  NUMBER,
stamp              IN  NUMBER,
xdf_key            OUT NUMBER,
file#              OUT NUMBER,
status             OUT VARCHAR2,
handle             OUT VARCHAR2,
completion_time    OUT DATE,
checkpoint_change# OUT NUMBER,
checkpoint_time    OUT DATE);
TBD
 
LISTTRANSLATERESTOREPOINT
Undocumented dbms_rcvman.listTranslateRestorePoint(name IN VARCHAR2);
TBD
 
LISTTRANSLATESPFILEBACKUP
Undocumented dbms_rcvman.listTranslateSPFileBackup(
completedAfter  IN DATE,
completedBefore IN DATE);
TBD
 
NUM2DISPLAYSIZE
Convert input number to displayable canonical format. The number is converted to nearest MB, GB, TB, or PB. dbms_rcvman.num2DisplaySize(input_size IN NUMBER) RETURN VARCHAR2;
SELECT dbms_rcvman.Num2DisplaySize(10240)
FROM dual;

SELECT dbms_rcvman.Num2DisplaySize(10485740)
FROM dual;

SELECT dbms_rcvman.Num2DisplaySize(10485740000)
FROM dual;

SELECT dbms_rcvman.Num2DisplaySize(10485740000000)
FROM dual;

SELECT dbms_rcvman.Num2DisplaySize(11255000000000000)
FROM dual;
 
PRINTRECOVERYACTIONS
Undocumented dbms_rcvman.printRecoveryActions;
exec dbms_rcvman.printRecoveryActions;
 
REPORTGETDFDEL
Report of deleted Data Files

Overload 1
dbms_rcvman.reportGetDFDel(
file#               OUT NUMBER,
filetype            OUT NUMBER,
checkpoint_change#  OUT NUMBER,
checkpoint_time     OUT DATE,
resetlogs_change#   OUT NUMBER,
resetlogs_time      OUT DATE,
incremental_change# OUT NUMBER,
fuzzy_change#       OUT NUMBER,
recid               OUT NUMBER,
stamp               OUT NUMBER,
fname               OUT VARCHAR2,
restorable          OUT NUMBER)
RETURN NUMBER;
Deprecated as of 8.1.6
Overload 2 dbms_rcvman.reportGetDFDel(
file#               OUT NUMBER,
filetype            OUT NUMBER,
checkpoint_change#  OUT NUMBER,
checkpoint_time     OUT DATE,
resetlogs_change#   OUT NUMBER,
resetlogs_time      OUT DATE,
incremental_change# OUT NUMBER,
fuzzy_change#       OUT NUMBER,
recid               OUT NUMBER,
stamp               OUT NUMBER,
fname               OUT VARCHAR2,
restorable          OUT NUMBER,
key                 OUT NUMBER,
completion_time     OUT DATE)
RETURN NUMBER;
TBD
 
REPORTTRANSLATEDFDEL
Undocumented dbms_rcvman.reportGetDFDel(
file#               OUT NUMBER,
filetype            OUT NUMBER,
checkpoint_change#  OUT NUMBER,
checkpoint_time     OUT DATE,
resetlogs_change#   OUT NUMBER,
resetlogs_time      OUT DATE,
incremental_change# OUT NUMBER,
fuzzy_change#       OUT NUMBER,
recid               OUT NUMBER,
stamp               OUT NUMBER,
fname               OUT VARCHAR2
restorable          OUT NUMBER)
RETURN NUMBER;
Deprecated as of 8.1.5
 
RESETALL
Calls resetUntil, setFrom, resetDeviceType and setTag to reset everything dbms_rcvman.resetAll(transclause IN BOOLEAN DEFAULT TRUE);
exec dbms_rcvman.resetAll(TRUE);
 
RESETDEVICETYPE
Resets the list of device types to null dbms_rcvman.resetDeviceType;
exec dbms_rcvman.resetDeviceType;
 
RESETPDBIDLIST (new 12.1)
Clear the pdbIdList that is used for translation dbms_rcvman.resetPDBIDList;
exec dbms_rcvman.resetPDBIDList;
 
RESETRECLRECID
Reset reclaimable record dbms_rcvman.resetReclRecID;
exec dbms_rcvman.resetReclRecID;
 
RESETTHISBACKUPAGE
Resets the current backup age value dbms_rcvman.resetThisBackupAge;
exec dbms_rcvman.resetThisBackupAge;
 
RESETUNTIL
Unsets the value indicating a complete recover dbms_rcvman.resetUntil;
exec dbms_rcvman.resetUntil;
 
SEC2DISPLAYTIME
Convert input seconds to displayable canonical format [HH:MI:SS] dbms_rcvman.Sec2DisplayTime(input_secs IN NUMBER) RETURN VARCHAR2;
SELECT dbms_rcvman.Sec2DisplayTime(1)
FROM dual;

SELECT dbms_rcvman.Sec2DisplayTime(61)
FROM dual;

SELECT dbms_rcvman.Sec2DisplayTime(86401)
FROM dual;
 
SETALLFLAG
Undocumented dbms_rcvman.setAllFlag(flag IN BOOLEAN);
Deprecated as of 8.1.6
 
SETALLINCARNATIONS
Undocumented: Deprecated as of 8.1.6 dbms_rcvman.setAllIncarnations(flag IN BOOLEAN);
exec dbms_rcvman.setAllIncarnations(TRUE);
 
SETARCHIVEDLOGRECORD
Hint to indicate the archivelog that is interested. Later, isTranslatedArchivedLog can be called to verify the presence. It doesn't take resetlogs information in order to keep it simple. Responsible for the client to validate further by comparing resetlogs information. dbms_rcvman.setArchivedLogRecord(
thread#   IN NUMBER,
sequence# IN NUMBER,
first     IN BOOLEAN);
TBD
 
SETARCHIVEFILESCOPEATTRIBUTES
Set Archive log file sharing scope attributes for the session dbms_rcvman.setArchiveFileScopeAttributes(logs_shared IN NUMBER);
TBD
 
SETBACKUPFILESCOPEATTRIBUTES
Sets Backup file sharing scope attributes for the session dbms_rcvman.setBackupFilesCopeAttributes(
disk_backups_shared IN NUMBER,
tape_backups_shared IN NUMBER);
TBD
 
SETCANAPPLYANYREDO
Undocumented dbms_rcvman.setCanApplyAnyRedo(flag IN BOOLEAN);
exec dbms_rcvman.setCanApplyAnyRedo(TRUE);
 
SETCANCONVERTCF
Used to tell that client is capable of control file conversion dbms_rcvman.setCanConvertCF(flag IN BOOLEAN);
exec dbms_rcvman.setCanConvertCF(TRUE);
 
SETCANHANDLETRANSPORTABLETBS
Indicates that the database can handle backup transportable tablespace. Make plugged readonly files visible for translation. dbms_rcvman.setCanHandleTransportableTBS(flag IN BOOLEAN);
exec dbms_rcvman.setCanHandleTransportableTBS(TRUE);
 
SETCOMPLETEDRANGE
Sets completedBefore and/or completedAfter filters for use by computeRecoveryActions dbms_rcvman.setCompletedRange(after IN DATE, before IN DATE);
exec dbms_rcvman.setCompletedRange(SYSDATE-2, SYSDATE);
 
SETCOMPUTERECOVERYACTIONMASKS
Undocumented
Overload 1
dbms_rcvman.setComputeRecoveryActionMasks(
containerMask IN NUMBER,
actionMask    IN NUMBER,
allRecords    IN NUMBER,
availableMask IN BINARY_INTEGER,
fullBackups   IN NUMBER DEFAULT NULL);
TBD
Overload 2 dbms_rcvman.setComputeRecoveryActionMasks(
containerMask IN NUMBER,
actionMask    IN NUMBER,
allRecords    IN NUMBER);
Deprecated as of 8.1.7
 
SETDATABASE
Selects which target database subsequent procedures operate on dbms_rcvman.setdatabase(
db_name        IN VARCHAR2,
reset_scn      IN NUMBER,
reset_time     IN DATE,
db_id          IN NUMBER,
db_unique_name IN VARCHAR2 DEFAULT NULL,
site_aware     IN BOOLEAN  DEFAULT FALSE,
dummy_instance IN BOOLEAN  DEFAULT FALSE);
conn rman/rman@repocat

desc v$backup_files

desc rc_backup_files

-- this will generate an error
SELECT COUNT(*)
FROM rc_backup_files;

SELECT name, resetlogs_change#, resetlogs_time
FROM v$database;

SELECT db_id FROM db;

-- substitutde your own DBID from the preceding query
exec dbms_rcvman.setDatabase('ORABASE', 940976, TO_DATE('11-APR-2013 16:05:25'), 318094786);

SELECT COUNT(*) FROM rc_backup_files;
 
SETDBIDTRANSCLAUSE
Set the current DBID dbms_rcvman.setDBIDTransClause(dbid IN NUMBER);
SELECT dbid FROM v$database;

SELECT dbms_rcvman.isTranslatedDbid(1746737380)
FROM dual;

exec dbms_rcvman.setDBIDTransClause(1746737380);

SELECT dbms_rcvman.isTranslatedDbid(1746737380)
FROM dual;
 
SETDBINCKEY
Used in lieu of setDatabase for when SET DBID command is issued dbms_rcvman.setDBIncKey(key IN NUMBER);
exec dbms_rcvman.setDBIncKey(1);
 
SETDEBUGOFF
Turn off debugging dbms_rcvman.setDebugOff;
exec dbms_rcvman.setDebugOff;
 
SETDEBUGON
Turn on debugging dbms_rcvman.setDebugOn;
exec dbms_rcvman.setDebugOn;
 
SETDEVICETYPE
Specifies the type of an allocated device. It may be 1 to 8 times, depending on the number of different device types that are allocated dbms_rcvman.setDeviceType(type IN VARCHAR2);
TBD
 
SETDEVICETYPEANY
Causes dbms_rcvman to return a backup set on ANY device type dbms_rcvman.setDeviceTypeAny;
exec dbms_rcvman.setDeviceTypeAny;
 
SETFROM
Used to limit the potential restore candidates to either backup sets or datafile copies, or to allow either kind of file to be used dbms_rcvman.setFrom(restorefrom IN NUMBER DEFAULT NULL);
exec dbms_rcvman.setFrom(dbms_rcvman.backup);
 
SETGETSINCELASTBACKEDAL
Sets the package variables to return all logs not backed ntimes to specific device type until sbpscn (standby became primary SCN) ignore needstby flag for the subsequent archivelog translations dbms_rcvman.setGetSinceLastBackedAL(
ntimes  IN NUMBER   DEFAULT 1,
devtype IN VARCHAR2 DEFAULT NULL,
sbpscn  IN NUMBER);
TBD
 
SETLIKEPATTERN
Sets the fileName patter for computeRecoveryActions dbms_rcvman.setLikePattern(pattern IN VARCHAR2);
TBD
 
SETNEEDOBSOLETEDATA
An optimization fix to not call computeRecoveryAction if client is not interested in obsolete column value dbms_rcvman.setNeedObsoleteData(NeedObsoleteData IN BOOLEAN DEFAULT TRUE);
exec dbms_rcvman.setNeedObsoleteData;
 
SETORSFILE (new 12.1)
Used to limit the translation only to ORS managed files dbms_rcvman.setORSFile(localOnly IN BOOLEAN, libKey IN NUMBER);
TBD
 
SETPDBID (new 12.1)
Clear the pdbIdList that is used for translation dbms_rcvman.setPDBID(setPdbId(pdbId IN NUMBER, first IN BOOLEAN);
exec dbms_rcvman.setPDBID(26, TRUE);
 
SETRAFLAGS
Undocumented dbms_rcvman.setRAflags(kindMask IN NUMBER, allRecords IN BOOLEAN);
Deprecated as of 8.1.6
 
SETRCVRECBACKUPAGE
Undocumented dbms_rcvman.setRcvRecBackupAge(age IN NUMBER);
TBD
 
SETRECLRECID
Set Reclaimable Record dbms_rcvman.setReclRecid(rectype IN BINARY_INTEGER, recid IN NUMBER);
TBD
 
SETRECOVERYDESTFILE
Used to limit the translation only to recovery area files. True means only recover area files: False means all files. dbms_rcvman.setRecoveryDestFile(onlyrdf IN BOOLEAN);
exec dbms_rcvman.setRecoveryDestFile(TRUE);
 
SETREDOLOGDELETIONPOLICY
Sets the Redo Log Deletion Policy dbms_rcvman.setRedoLogDeletionPolicy(policy IN VARCHAR2, alldest IN NUMBER);
See getSCNForAppliedPolicy Demo Above
 
SETSITENAME
Set a site name in catalog all the translation will happen against this site dbms_rcvman.setSiteName(db_unique_name IN VARCHAR2, for_realfiles IN NUMBER);
TBD
 
SETSTANDBY
Undocumented dbms_rcvman.setStandby(stby IN BOOLEAN);
exec dbms_rcvman.setStandby(FALSE);
 
SETTAG
Limits restore candidates to backups and copies with the given tag. If NULL then all backups and copies are searched by the find functions. dbms_rcvman.setTag(tag IN VARCHAR2 DEFAULT NULL);
TBD
 
SETTOLOG
Undocumented dbms_rcvman.setToLog(sequence# IN NUMBER, thread# IN NUMBER);
TBD
 
SETUNTILLOG
Undocumented dbms_rcvman.setUntilLog(sequence# IN NUMBER, thread# IN NUMBER);
TBD
 
SETUNTILRESETLOGS
Undocumented dbms_rcvman.setUntilResetLogs;
exec dbms_rcvman.setUntilResetLogs;
 
SETUNTILSCN
Undocumented dbms_rcvman.setUntilScn(
scn     IN NUMBER,
rlgscn  IN NUMBER  DEFAULT NULL,
rlgtime IN DATE    DEFAULT NULL,
flbrp   IN BOOLEAN DEFAULT FALSE,
rpoint  IN BOOLEAN DEFAULT FALSE);
TBD
 
SETUNTILTIME
Undocumented dbms_rcvman.setUntilTime(unttime IN DATE);
See GETUNTILTIME Demo Above
 
SET_PACKAGE_CONSTANTS
Undocumented dbms_rcvman.set_Package_Constants;
exec dbms_rcvman.set_Package_Constants;
 
SKIPTABLESPACE
Exclude the named tablespace from processing dbms_rcvman.skipTablespace(ts_name IN VARCHAR2);
exec dbms_rcvman.skipTablespace('UWDATA');
 
STAMP2DATE
Converts and integer into its corresponding date and time dbms_rcvman.stamp2date(stamp IN NUMBER) RETURN DATE;
SELECT dbms_rcvman.stamp2date(691299999)
FROM dual;
 
SV_GETSESSIONFROMTIMERANGE
Retrieves the "from" time for job views dbms_rcvman.sv_getSessionfromTimeRange RETURN DATE;
See SV_SETSESSIONTIMERANGE Demo below
 
SV_GETSESSIONKEY
Retrieves the session key for job views dbms_rcvman.sv_getSessionKey RETURN NUMBER;
See SV_SETSESSIONKEY Demo below
 
SV_GETSESSIONUNTILTIMERANGE
Retrieves the "until" time for job views dbms_rcvman.sv_getSessionUntilTimeRange RETURN DATE;
See SV_SETSESSIONTIMERANGE Demo below
 
SV_SETSESSIONKEY
Sets the session key for job views dbms_rcvman.sv_setSessionKey(skey IN NUMBER);
exec dbms_rcvman.sv_setSessionKey(42);

SELECT dbms_rcvman.sv_getSessionKey
FROM dual;

exec dbms_rcvman.sv_setSessionKey;
 
SV_SETSESSIONTIMERANGE
Sets the session time range for job views dbms_rcvman.sv_setSessionTimeRange(fromTime IN DATE, untilTime IN DATE);
exec dbms_rcvman.sv_setSessionTimeRange(SYSDATE, SYSDATE+1/24);

SELECT dbms_rcvman.sv_getSessionFromTimeRange
FROM dual;

SELECT dbms_rcvman.sv_getSessionUntilTimeRange
FROM dual;

exec dbms_rcvman.sv_setSessionTimeRange(NULL, NULL);
 
TRANSLATEALLBACKUPSET
Undocumented dbms_rcvman.translateAllBackupSet(
backupType      IN BINARY_INTEGER,
tag             IN VARCHAR2,
statusMask      IN BINARY_INTEGER,
completedAfter  IN DATE,
completedBefore IN DATE,
onlyrdf         IN BINARY_INTEGER DEFAULT 0);
TBD
 
TRANSLATEALLDATAFILE
Returns a list of all datafiles that ever existed in this database dbms_rcvman.translateAllDatafile;
exec dbms_rcvman.translateAllDatafile;
 
TRANSLATEARCHIVEDLOGCANCEL
Undocumented dbms_rcvman.translateArchivedLogCancel;
exec dbms_rcvman.translateArchivedLogCancel;
 
TRANSLATEARCHIVEDLOGKEY
Translates the archived log key to a archived log recid and stamp in V$ARCHIVED_LOG dbms_rcvman.translateArchivedLogKey(
al_key      IN  NUMBER,
available   IN  NUMBER DEFAULT 1, -- ignored (for compatability)
unavailable IN  NUMBER DEFAULT 1, -- ignored (for compatability)
deleted     IN  NUMBER DEFAULT 1, -- ignored (for compatability)
online      IN  NUMBER DEFAULT 1, -- ignored (for compatability)
recid       OUT NUMBER,
stamp       OUT NUMBER,
thread#     OUT NUMBER,
sequence#   OUT NUMBER,
low_scn     OUT NUMBER,
reset_scn   OUT NUMBER,
block_size  OUT NUMBER,
fname       OUT VARCHAR2,
needstby    IN  NUMBER DEFAULT NULL);
TBD
 
TRANSLATEARCHIVEDLOGNAME
Undocumented dbms_rcvman.translateArchivedLogName(
fname       IN VARCHAR2,
available   IN NUMBER DEFAULT NULL,         -- for compatability
unavailable IN NUMBER DEFAULT NULL,         -- for compatability
deleted     IN NUMBER DEFAULT NULL,         -- for compatability
online      IN NUMBER,                      -- ignored
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL, -- for compatability
needstby    IN NUMBER DEFAULT NULL;         -- for compatability
TBD
 
TRANSLATEARCHIVEDLOGPATTERN
Undocumented dbms_rcvman.translateArchivedLogPattern(
pattern     IN VARCHAR2,
available   IN NUMBER DEFAULT NULL,         -- for compatability
unavailable IN NUMBER DEFAULT NULL,         -- for compatability
deleted     IN NUMBER DEFAULT NULL,         -- for compatability
online      IN NUMBER,                      -- ignored
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL, -- for compatability
needstby    IN NUMBER DEFAULT NULL,         -- for compatability
foreignal   IN BINARY_INTEGER DEFAULT 0);   -- for compatability
TBD
 
TRANSLATEARCHIVEDLOGSCNRANGE
Undocumented dbms_rcvman.translateArchivedLogSCNRange(
thread#       IN NUMBER,
fromSCN       IN NUMBER,
toSCN         IN NUMBER,
pattern       IN VARCHAR2,
available     IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable   IN NUMBER         DEFAULT NULL,  -- for compatability
eleted        IN NUMBER         DEFAULT NULL,  -- for compatability
online        IN NUMBER,
duplicates    IN NUMBER,
statusMask    IN BINARY_INTEGER DEFAULT NULL,  -- for compatability
needstby      IN NUMBER         DEFAULT NULL,
doingRecovery IN NUMBER         DEFAULT FALSE#,
onlyrdf       IN BINARY_INTEGER DEFAULT 0,     -- for compatability
reset_scn     IN NUMBER         DEFAULT NULL,  -- for compatability
reset_time    IN DATE           DEFAULT NULL,  -- for compatability
sequence#     IN NUMBER         DEFAULT NULL,  -- for compatability
foreignal     IN BINARY_INTEGER DEFAULT 0,     -- for compatability
incarn        IN NUMBER         DEFAULT NULL); -- for compatibility
TBD
 
TRANSLATEARCHIVEDLOGSEQRANGE
Undocumented dbms_rcvman.translateArchivedLogSeqRange(
thread#     IN NUMBER,
fromseq#    IN NUMBER,
toseq#      IN NUMBER,
pattern     IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
deleted     IN NUMBER         DEFAULT NULL,  -- for compatability
online      IN NUMBER,                       -- ignored
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL,  -- for compatability
needstby    IN NUMBER         DEFAULT NULL,  -- for compatability
foreignal   IN BINARY_INTEGER DEFAULT 0,     -- for compatability
incarn      IN NUMBER         DEFAULT NULL); -- for compatibility
TBD
 
TRANSLATEARCHIVEDLOGTIMERANGE
Undocumented dbms_rcvman.translateArchivedLogTimeRange(
thread#     IN NUMBER,
fromTime    IN DATE,
toTime      IN DATE,
pattern     IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
deleted     IN NUMBER         DEFAULT NULL,  -- for compatability
online      IN NUMBER,                       -- ignored
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL,  -- for compatability
needstby    IN NUMBER         DEFAULT NULL,  -- for compatability
foreignal   IN BINARY_INTEGER DEFAULT 0,     -- for compatability
incarn      IN NUMBER         DEFAULT NULL); -- for compatibility
TBD
 
TRANSLATEBACKUPFILE
Undocumented dbms_rcvman.translateBackupFile(
bs_recid    IN  NUMBER,
bs_stamp    IN  NUMBER,
fno         IN  NUMBER,
bskey       OUT NUMBER,
inclevel    OUT NUMBER,
backup_type OUT VARCHAR2,
completed   OUT DATE);
8.1.5 LIST implementation
 
TRANSLATEBACKUPPIECEBSKEY
Translates the specified backup set into a list of backup pieces

Overload 1
dbms_rcvman.translateBackupPieceBSKey(
key         IN NUMBER,
tag         IN VARCHAR2       DEFAULT NULL,
deviceType  IN VARCHAR2       DEFAULT NULL,
pieceCount  IN NUMBER,
duplicates  IN NUMBER         DEFAULT TRUE#,
copyNumber  IN NUMBER         DEFAULT NULL,
available   IN NUMBER         DEFAULT TRUE#,
unavailable IN NUMBER         DEFAULT FALSE#,
deleted     IN NUMBER         DEFAULT FALSE#,
expired     IN NUMBER         DEFAULT FALSE#,
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateBackupPieceBSKey(
startBsKey IN NUMBER,
tag        IN VARCHAR2       DEFAULT NULL,
statusMask IN BINARY_INTEGER DEFAULT NULL);
TBD
 
TRANSLATEBACKUPPIECEHANDLE
Looks up a backup piece by handle and deviceType

Overload 1
dbms_rcvman.translateBackupPieceHandle(
handle      IN VARCHAR2,
deviceType  IN VARCHAR2,
available   IN NUMBER DEFAULT NULL, -- for compatability
unavailable IN NUMBER DEFAULT NULL, -- for compatability
expired     IN NUMBER DEFAULT NULL, -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateBackupPieceHandle(
handle      IN  VARCHAR2,
device_type IN  VARCHAR2,
available   IN  NUMBER,
unavailable IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
set_stamp   OUT NUMBER,
set_count   OUT NUMBER,
piece#      OUT NUMBER);
Only used in 8.1.6
 
TRANSLATEBACKUPPIECEKEY
Looks up a backup piece by primary key

Overload 1
dbms_rcvman.translateBackupPieceKey(
key         IN NUMBER,
available   IN NUMBER         DEFAULT TRUE#,
unavailable IN NUMBER         DEFAULT TRUE#,
expired     IN NUMBER         DEFAULT TRUE#,
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateBackupPieceKey(
bp_key      IN  NUMBER,
available   IN  NUMBER,
unavailable IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
handle      OUT VARCHAR2,
set_stamp   OUT NUMBER,
set_count   OUT NUMBER,
piece#      OUT NUMBER);
Only used in 8.1.6
 
TRANSLATEBACKUPPIECETAG
Looks up backup pieces by tag dbms_rcvman.translateBackupPieceTag(
tag         IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
 
TRANSLATEBACKUPSETKEY
Undocumented

Overload 1
dbms_rcvman.translateBackupSetKey(
bs_key          IN  NUMBER,
device_type     IN  VARCHAR2,
available       IN  NUMBER,
unavailable     IN  NUMBER,
deleted         IN  NUMBER,
duplicates      IN  NUMBER,
backup_type     OUT VARCHAR2,
recid           OUT NUMBER,
stamp           OUT NUMBER,
set_stamp       OUT NUMBER,
set_count       OUT NUMBER,
bslevel         OUT NUMBER,
completion_time OUT DATE);
Deprecated as of 8.1.6
Overload 2 dbms_rcvman.translateBackupSetKey(
bs_key      IN  NUMBER,
device_type IN  VARCHAR2,
available   IN  NUMBER,
unavailable IN  NUMBER,
deleted     IN  NUMBER,
duplicates  IN  NUMBER,
backup_type OUT VARCHAR2,
recid       OUT NUMBER,
stamp       OUT NUMBER);
Deprecated as of 8.1
Overload 3 dbms_rcvman.translateBackupSetKey(key IN NUMBER, bsRec OUT NOCOPY bsRec_t);
TBD
 
TRANSLATEBACKUPSETRECID
Undocumented

Overload 1
dbms_rcvman.translateBackupSetRecID(
recid       IN  NUMBER,
stamp       IN  NUMBER,
device_type IN  VARCHAR2,
bs_key      OUT NUMBER,
bslevel     OUT NUMBER,
completed   OUT DATE);
TBD
Overload 2 dbms_rcvman.translateBackupSetRecID(
recid       IN NUMBER,
stamp       IN NUMBER,
device_type IN VARCHAR2);
Deprecated as of 8.1
 
TRANSLATEBPBSKEYCANCEL
End the translation once you are done with fetching pieces of all backupsets. This will close the cursor and reset the package translation variables. dbms_rcvman.translateBpBsKeyCancel;
TBD
 
TRANSLATECONTROLFILECOPYKEY
Undocumented dbms_rcvman.translateControlFileCopyKey(
key         IN NUMBER,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
 
TRANSLATECONTROLFILECOPYNAME
Translates a control file name into a list of  control file copies dbms_rcvman.translateControlFileCopyName(
fname       IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL, -- for compatability
unavailable IN NUMBER         DEFAULT NULL, -- for compatability
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL, -- for compatability
onlyone     IN NUMBER         DEFAULT 1);
TBD
 
TRANSLATECONTROLFILECOPYTAG
Undocumented dbms_rcvman.translateControlFileCopyTag(
cftag       IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL, -- for compatability
unavailable IN NUMBER         DEFAULT NULL, -- for compatability
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL, -- for compatability
onlyone     IN NUMBER         DEFAULT 1);
TBD
 
TRANSLATECORRUPTLIST
Undocumented dbms_rcvman.translateCorruptList;
exec dbms_rcvman.translateCorruptList;
 
TRANSLATEDATABASE
Translates the database into a list of datafile numbers in the database excluding datafiles belonging to tablespaces specified using skipTableSpace dbms_rcvman.translateDatabase(sinceUntilSCN IN NUMBER DEFAULT NULL);
SELECT current_scn
FROM v$database;

exec dbms_rcvman.translateDatabase(64158474);
 
TRANSLATEDATAFILE
Translates the datafile name/number into a datafile number and creation SCN and filename
Overload 1
dbms_rcvman.translateDataFile(fname IN VARCHAR2);
exec dbms_rcvman.translateDataFile('u01/oradata/orabaes/uwdata01.dbf');
Overload 2 dbms_rcvman.translateDataFile(fno IN NUMBER);
exec dbms_rcvman.translateDataFile(6);
Overload 3 dbms_rcvman.translateDataFilefno IN NUMBER, ckpscn IN NUMBER);
TBD
 
TRANSLATEDATAFILECANCEL
Undocumented dbms_rcvman.translateDataFileCancel;
exec dbms_rcvman.translateDataFileCancel;
 
TRANSLATEDATAFILECOPY
Translates the datafile copy key into a datafile copy recid and stamp in V$DATAFILE_COPY

Overload 1
dbms_rcvman.translateDataFileCopy(
cdf_key     IN NUMBER,
available   IN NUMBER         DEFAULT NULL, -- for compatability
unavailable IN NUMBER         DEFAULT NULL, -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateDataFileCopy(
cdf_key     IN  NUMBER,
available   IN  NUMBER,
unavailable IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
file#       OUT NUMBER,
fname       OUT VARCHAR2,
reset_scn   OUT NUMBER,
create_scn  OUT NUMBER,
ckp_scn     OUT NUMBER,
block_size  OUT NUMBER,
blocks      OUT NUMBER);
Deprecated as of 8.1.6
 
TRANSLATEDATAFILECOPYFNO
Translates a file number into a list of datafile  copies dbms_rcvman.translateDataFileCopyFNO(
fno         IN NUMBER,
available   IN NUMBER         DEFAULT NULL,
unavailable IN NUMBER         DEFAULT NULL,
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL,
pluginSCN   IN NUMBER         DEFAULT 0);
TBD
 
TRANSLATEDATAFILECOPYKEY
Translates the datafile copy key into a datafile copy recid and stamp in V$DATAFILE_COPY

Overload 1
dbms_rcvman.translateDataFileCopyKey(
cdf_key     IN NUMBER,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateDataFileCopyKey(
cdf_key     IN  NUMBER,
available   IN  NUMBER,
unavailable IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
file#       OUT NUMBER,
fname       OUT VARCHAR2,
reset_scn   OUT NUMBER,
create_scn  OUT NUMBER,
ckp_scn     OUT NUMBER,
block_size  OUT NUMBER,
blocks      OUT NUMBER);
TBD
 
TRANSLATEDATAFILECOPYNAME
Undocumented dbms_rcvman.translateDataFileCopyName(
fname       IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL, -- for compatability
unavailable IN NUMBER         DEFAULT NULL, -- for compatability
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL, -- for compatability
onlyone     IN NUMBER         DEFAULT 1,
pluginSCN   IN NUMBER         DEFAULT 0);
TBD
 
TRANSLATEDATAFILECOPYTAG
Translates the tag into a list of datafile copies and getDataFileCopy returns the recid and stamp of each datafile copy one at a time until null is returned dbms_rcvman.translateDataFileCopyTag(
tag         IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,    -- for compatability
unavailable IN NUMBER         DEFAULT NULL,    -- for compatability
duplicates  IN NUMBER,
statusMask  IN BINARY_INTEGER DEFAULT NULL,    -- for compatability
pluginSCN   IN NUMBER         DEFAULT 0,
onlytc      IN BINARY_INTEGER DEFAULT FALSE#); -- for compatibility
TBD
 
TRANSLATEFAILURE
Called to open the cursor in order to retrieve the list of failures (using getFailure) from ADR dbms_rcvman.translateFailure(
critical IN BINARY_INTEGER,
high     IN BINARY_INTEGER,
low      IN BINARY_INTEGER,
closed   IN BINARY_INTEGER,
adviseId IN NUMBER);
TBD
 
TRANSLATEMANUALREPAIR
Open the cursors to retrieve the list of manual repairs (using getManualRepair) dbms_rcvman.translateManualRepair(adviseId IN NUMBER);
See GETMANUALREPAIR Demo Above
 
TRANSLATEONLINELOGS
Translates the database to a list of online redo logs. The translation is always performed relative to current epoch. dbms_rcvman.translateOnlineLogs(srls IN NUMBER DEFAULT 0);
TBD
 
TRANSLATEPDB2NAME (new 12.1)
Translates a PDB ID to a PDB name dbms_rcvman.translatePDB2Name(pdbId IN NUMBER) RETURN VARCHAR2;
SELECT dbms_rcvman.translatePDB2Name(3)
FROM dual;
 
TRANSLATEPDBNAME (new 12.1)
Translates a PDB Name to a PDB ID dbms_rcvman.translatePDB2Name(pdbName IN VARCHAR2) RETURN NUMBER;
SELECT dbms_rcvman.translatePDBName('PDBORCL')
FROM dual;
 
TRANSLATEPROXYCOPYHANDLE
Translates handle and device type to a proxy copy recid and stamp

Overload 1
dbms_rcvman.translateProxyCopyHandle(
handle      IN VARCHAR2,
deviceType  IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL, -- for compatability
unavailable IN NUMBER         DEFAULT NULL, -- for compatability
deleted     IN NUMBER         DEFAULT NULL, -- for compatability
expired     IN NUMBER         DEFAULT NULL, -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateProxyCopyHandle(
handle      IN  VARCHAR2,
device_type IN  VARCHAR2,
available   IN  NUMBER,
unavailable IN  NUMBER,
deleted     IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER);
Deprecated as of 8.1.6
 
TRANSLATEPROXYCOPYKEY
Translates a proxy copy key to a recid and stamp in V$PROXY_DATAFILE/V$PROXY_ARCHIVEDLOG. Translates handle and device type to a proxy copy recid and stamp

Overload 1
dbms_rcvman.translateProxyCopyKey(
pc_key      IN NUMBER,
deviceType  IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
deleted     IN NUMBER         DEFAULT NULL,  -- for compatability
expired     IN NUMBER         DEFAULT NULL,  -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
Overload 2 dbms_rcvman.translateProxyCopyKey(
pc_key      IN  NUMBER,
device_type IN  VARCHAR2,
available   IN  NUMBER,
unavailable IN  NUMBER,
deleted     IN  NUMBER,
recid       OUT NUMBER,
stamp       OUT NUMBER,
handle      OUT VARCHAR2);
Deprecated as of 8.1.6
 
TRANSLATEPROXYCOPYTAG
Undocumented dbms_rcvman.translateProxyCopyTag(
tag         IN VARCHAR2,
device_type IN VARCHAR2,
available   IN NUMBER         DEFAULT NULL,  -- for compatability
unavailable IN NUMBER         DEFAULT NULL,  -- for compatability
deleted     IN NUMBER         DEFAULT NULL,  -- for compatability
statusMask  IN BINARY_INTEGER DEFAULT NULL); -- for compatability
TBD
 
TRANSLATEREPAIR
Opens the cursor in order to retrieve the list of repair option (using getRepair) dbms_rcvman.translateRepair(adviseid IN NUMBER);
See GETREPAIR Demo Above
 
TRANSLATEREPAIROPTION
Opens the cursor in order to retrieve the list of repair option (using getRepairOption) dbms_rcvman.translateRepairOption(adviseid IN NUMBER);
See GETREPAIROPTION Demo Above
 
TRANSLATEREPAIRPARMS
Opens the cursor in order to retrieve a list of repair parameters (using getRepairParms) dbms_rcvman.translateRepairParms(adviseid IN NUMBER);
See GETREPAIRPARMS Demo Above
 
TRANSLATEREPAIRSTEP
Called to open the cursor in order to retrieve the list of repair step (using getRepairStep) dbms_rcvman.translateRepairStep(optionidx IN NUMBER);
exec dbms_rcvman.translateRepairStep(0);
 
TRANSLATESEEKBPBSKEY
Used seek to a specified backupset key, device, copyNumber. May return no_data_found if the backupset key is not found or the cursor have passed over the backupset key, device, copyNumber. dbms_rcvman.translateSeekBpBsKey(
bsKey      IN NUMBER,
deviceType IN VARCHAR2,
pieceCount IN NUMBER,
duplicates IN NUMBER DEFAULT TRUE#,
copyNumber IN NUMBER DEFAULT NULL);
TBD
 
TRANSLATETABLESPACE
Translates a tablespace name into a list of datafile numbers dbms_rcvman.translateTablespace(ts_name IN VARCHAR2);
SELECT dbid
FROM v$database;

exec dbms_rcvman.setDatabase(NULL,NULL,NULL,NULL,411390437);

exec dbms_rcvman.translateTablespace('ORADATA');
 
TRANSLATETEMPFILE
Translates tempfiles known to database in current incarnation
Overload 1
dbms_rcvman.translateTempFile;
exec dbms_rcvman.translateTempFile;
Overload 2 dbms_rcvman.translateTempFile(fname IN VARCHAR2);
exec dbms_rcvman.translateTempFile('C:\ORACLE\PRODUCT\ORADATA\ORABASE\TEMP01.DBF');
Overload 3 dbms_rcvman.translateTempFile(fno IN NUMBER);
exec dbms_rcvman.translateTempFile(6);
 
TRIMRECOVERYACTIONS
Trim the stack down to the specified number actions if it contains more. This is used by report obsolete to implement the redundancy count. dbms_rcvman.trimRecoveryActions(
maxActions    IN NUMBER,
containerMask IN NUMBER,
actionMask    IN NUMBER);
TBD
 
VALIDATESTANDBYCONFIG
Return archivelogs records that has been applied on all destinations specified by validateStandbyConfig TARGET string and redoLogDeletionPolicy dbms_rcvman.validateStandbyConfig(policy IN VARCHAR2, alldest IN NUMBER)
RETURN NUMBER;
TBD
 
WASFILEOFFLINE
Undocumented dbms_rcvman.wasFileOffLine(fno IN NUMBER, untilscn IN NUMBER)
RETURN NUMBER;
SELECT dbms_rcvman.wasFileOffLine(6, 5000000)
FROM dual;

Related Topics
Backup, Restore, Recover
DBMS_BACKUP_RESTORE
DBMS_RCVCAT
Packages
RMAN
RMAN Demos

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-2014 Daniel A. Morgan All Rights Reserved