Can you explain how the following query works?
"alter database recover automatic using backup control file until cancel;"
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
This really isn't a query but rather a command. Basically, the command above will recover from a situation where you lost your control files and have to use a backup control file, which is out of sync with the database. The USING BACKUP CONTROLFILE clause instructs Oracle that recovery of the database will be performed with incomplete information. If you had a current control file, it would know the last transaction number (SCN) and stop recovery once that transaction has been reached. Since you do not know the last SCN, Oracle does not know when to stop. So it is up to the DBA to tell Oracle when to cancel the application of recovery, hence the UNTIL CANCEL clause.
Dig Deeper on Oracle database administration
Oracle expert Brian Peasland answers one reader's question about common pitfalls when connecting Oracle to outside programs.continue reading
One reader asks expert Brian Peasland a question about datafile sizes with the Oracle RMAN duplicate 10g command.continue reading
Managing parent table-child table relations in Oracle SQL environments is key to efficient programming.continue reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.