Set Date format inside RMAN environment

Suppose inside rman environment I got the following output.
RMAN> list backup;

using target database control file instead of recovery catalog

List of Backup Sets
===================

BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
1 Full 558.80M DISK 00:01:14 08-SEP-08
BP Key: 1 Status: AVAILABLE Compressed: NO Tag: TAG20080908T035835
Piece Name: /oracle/app/oracle/product/10.2.0/db_1/flash_recovery_area/SHAIK/backupset/
2008_09_08/o1_mf_nnndf_TAG20080908T035835_4d9pscwz_.bkp
List of Datafiles in backup set 1
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 1030282 08-SEP-08 /oradata2/shaikdba/shaikdba/shaik/system01.dbf
2 Full 1030282 08-SEP-08 /oradata2/shaikdba/shaikdba/shaik/undotbs01.dbf
3 Full 1030282 08-SEP-08 /oradata2/shaikdba/shaikdba/shaik/sysaux01.dbf
4 Full 1030282 08-SEP-08 /oradata2/shaikdba/shaikdba/shaik/users01.dbf

.
.
.

Here I get date as 08-SEP-08 which only shows date, month and year. The exact minute, hour and second are not displayed here. In order to get output as hour,minute second along with above output I have to set NLS_DATE_FORMAT. Note that this need to be set in OS level. Suppose in my bash shell, I have set
-bash-3.00$ export NLS_DATE_FORMAT='DD-MON-YY HH24:MI:SS'
Ans now it returns as I wanted.
RMAN> list backup;

using target database control file instead of recovery catalog

List of Backup Sets
===================

BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ------------------
1 Full 558.80M DISK 00:01:14 08-SEP-08 03:59:49
BP Key: 1 Status: AVAILABLE Compressed: NO Tag: TAG20080908T035835
Piece Name: /oracle/app/oracle/product/10.2.0/db_1/flash_recovery_area/SHAIK/backupset/
2008_09_08/o1_mf_nnndf_TAG20080908T035835_4d9pscwz_.bkp
List of Datafiles in backup set 1
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- ------------------ ----
1 Full 1030282 08-SEP-08 03:58:35 /oradata2/shaikdba/shaikdba/shaik/system01.dbf
2 Full 1030282 08-SEP-08 03:58:35 /oradata2/shaikdba/shaikdba/shaik/undotbs01.dbf
3 Full 1030282 08-SEP-08 03:58:35 /oradata2/shaikdba/shaikdba/shaik/sysaux01.dbf
4 Full 1030282 08-SEP-08 03:58:35 /oradata2/shaikdba/shaikdba/shaik/users01.dbf

On windows you have to set as,
>set NLS_DATE_FORMAT=MON DD, YYYY HH24:MI:SS

Comments

Popular posts from this blog

ORA-04062: timestamp of procedure has been changed

ORA-00939: too many arguments -when case arguments exceed 255

ORA-31655: no data or metadata objects selected for job