ORA-00907: Missing Right Parenthesis

Today to run a RMAN script to perform a restore of a database gives me this error;


RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================

RMAN-03002: failure of set command at 08/20/2015 08:41:34
ORA-00907: missing right parenthesis

Error literally says, missing a right parenthesis, but here is another mistake, I thought it originally occurred, and so I have made you a post. This is the part of the code is wrong (excerpt from script);


run {
allocate channel t1 type 'SBT_TAPE' parms 'ENV=(NSR_SERVER=SRVBCK_PROD,
NSR_DATA_VOLUME_POOL=HotBackup_Full,
NSR_CLIENT=Lion)';
set until time "to_date( 'AUG 17 2015 05:00:00' , 'MON DD RRRR HH24:MI:SS')";
SET NEWNAME FOR DATAFILE '+STORAGE_PRIMARY/DATAFILE/CLOUD_SYSTEM_1.DBS' TO '+RESTORE-TEMPORAL/CLOUD_SYSTEM_1.DBS';
SET NEWNAME FOR DATAFILE '+STORAGE_PRIMARY/DATAFILE/CLOUD_SYSAUX_1.DBS' TO '+RESTORE-TEMPORAL/CLOUD_SYSAUX_1.DBS';

The problem is that I put the month in Spanish, the language is in English, changing it to “aug” the problem is solved, as shown below;

run {
allocate channel t1 type 'SBT_TAPE' parms 'ENV=(NSR_SERVER=SRVBCK_PROD,
NSR_DATA_VOLUME_POOL=HotBackup_Full,
NSR_CLIENT=Lion)';
set until time "to_date( 'AUG 17 2015 05:00:00' , 'MON DD RRRR HH24:MI:SS')";
SET NEWNAME FOR DATAFILE '+STORAGE_PRIMARY/DATAFILE/CLOUD_SYSTEM_1.DBS' TO '+RESTORE-TEMPORAL/CLOUD_SYSTEM_1.DBS';
SET NEWNAME FOR DATAFILE '+STORAGE_PRIMARY/DATAFILE/CLOUD_SYSAUX_1.DBS' TO '+RESTORE-TEMPORAL/CLOUD_SYSAUX_1.DBS';

Is curious error, it really is syntax and Oracle can not fit more or indicate an “invalid value” or “invalid month”.

HTH – Antonio NAVARRO

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s