Add date to backup controlfile to trace command
623368Mar 23 2009 — edited Mar 24 2009A little background:
I'm writting a rman script and want to include a controlfile to trace and a pfile.
The commands I'm using are:
alter database backup controlfile to trace as 'd:\oracle\backup\controlfile.bak';
create pfile='d:\oracle\backup\pfile.bak' from spfile;
However, I want the file to be controlfile.bak.theDate, ie controlfile.bak.20090323, as I want to keep so many days worth and not overwrite the file.
How can I add the date in this way?
Thanks in advance.