Multiple choice technology databases

You discover that a disk failure occured on DISK3 where the data file belonging to the USER_DATA table is stored. The database is currently open and you need to recover the data file. You will restore the data file to DISK2. what is the correct sequence RMAN commands to restore and recover the data file ?

  1. RUN { RESTORE TABLESPACE user_data; RECOVER TABLESPACE user_data; ALTER DATABASE OPEN; }

  2. RUN { ET NEWNAME FOR '/DISK3/user_data01.dbf' TO '/DISK2/user_data01.dbf'; RESTORE TABLESPACE user_data; SWITCH DATAFILE '/DISK3/user_data01.dbf';

  3. RUN { RESTORE TABLESPACE user_data; SET NEWNAME FOR '/DISK3/user_data01.dbf' TO '/DISK2/user_data01.dbf'; SWITCH DATAFILE '/DISK3/user_data01.dbf';

  4. RUN { SET NEWNAME FOR '/DISK3/user_data01.dbf' TO '/DISK2/user_data01.dbf'; RESTORE TABLESPACE user_data; RECOVER TABLESPACE user_data; ALTER DATABASE OPEN;}

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The correct sequence begins with SET NEWNAME to specify the new location, followed by RESTORE to recover the datafile to that location. The SWITCH DATAFILE command then updates the control file to reflect the new location. This order ensures proper restoration and control file updates when moving a datafile during recovery.