Oracle Error Message
RMAN-03031: this option of set command needs to be used inside a run block
Reason for the Error
The option used with the SET command is not valid outside a run block.
Solution
Change the SET command or place it inside a run block.