Good morning,
I have a philosophical question.
Imagine I have a daily BACKUP AS COPY DATABASE command with the REUSE parameter (the datafiles are overwritten every time the backup is run). This database has 10 datafiles.
Imagine this timeline of events:
- DAY 1. The BACKUP AS COPY DATABASE REUSE is started, it ends OK. It generates a database replica with the 10 datafiles.
- Archives are generated
- DAY 2. The BACKUP AS COPY DATABASE REUSE is executed, but, due to some power failure everything shutsdown during the BACKUP AS COPY command. 5 datafiles are copied but 5 datafiles are not
- We recover the host and the original database is wiped out, we need to restore from copy. We have a copy of 5 datafiles from DAY 1 and a copy for the other 5 datafiles from DAY 2 (with the REUSE command, the last 5 files have been overwritten)
Would we be able to restore the database as it was seconds before the crash (aka last archive)?
i. e.
- Restore datafiles from day 1
- Restore datafiles from day 2
- Apply archives until day 2 is reached.
or
- No. You won't have a full backup and you're doomed.
or
- It depends if the DAY 2 datafiles are SYSTEM datafiles or User datafiles.
or
- WHAT! what are you doing overwriting the copy without a previous copy to tape or others? Imagine this answer is not available because then there would be no philosophical question.
I'd like to try this out, but maybe someone has already tried.
Regards, thanks for reading,