MERCADOS FINANCIEROS

lunes, 24 de mayo de 2021

DB_FILE_NAME_CONVERT


db_file_name_convert=('/u02/oradata/proddb01/datafile','/u02/oradata/testdb01',
                      '/u02/oradata/proddb01/tempfile',/u02/oradata/testdb01')

log_file_name_convert=('proddb01','testdb01')
When using an spfile:
alter system set db_file_name_convert='/u02/oradata/proddb01/datafile','/u02/oradata/testdb01',
                                      '/u02/oradata/proddb01/tempfile',/u02/oradata/testdb01' scope=spfile;

alter system set log_file_name_convert='proddb01','testdb01' scope=spfile;

miércoles, 12 de mayo de 2021

ALTER DATABASE CLEAR LOGFILE - GRUPOS DE REDOLOG

SQL> select group#,status from v$log;

    GROUP# STATUS

---------- ----------------

1 CURRENT

2 ACTIVE

3 INACTIVE


PROCEDIMIENTO INACTIVE

sql> alter database clear logfile group #;

PROCEDIMIENTO ACTIVE

sql> alter database clear unarchived logfile group # 

PROCEDIMIENTO CURRENT

 sql> alter database clear unarchived logfile group 1 unrecoverable datafile;

DAÑO ARCHIVO DE CONTROL

PROCEDIMIENTO I

 SQL>startup nomount;


RMAN> STARTUP NOMOUNT;

RMAN> ALTER DATABASE MOUNT;

RMAN> RECOVER DATABASE;

RMAN> ALTER DATABASE OPEN RESETLOGS;



lunes, 10 de mayo de 2021

ANALYZE TABLE

 The following statement analyzes the emp table:

ANALYZE TABLE emp VALIDATE STRUCTURE;

You can validate an object and all dependent objects (for example, indexes) by including the CASCADE option. The following statement validates the emp table and all associated indexes:

ANALYZE TABLE emp VALIDATE STRUCTURE CASCADE;

By default the CASCADE option performs a complete validation. Because this operation can be resource intensive, you can perform a faster version of the validation by using the FAST clause. This version checks for the existence of corruptions using an optimized check algorithm, but does not report details about the corruption. If the FAST check finds a corruption, you can then use the CASCADE option without the FAST clause to locate it. The following statement performs a fast validation on the emp table and all associated indexes:

ANALYZE TABLE emp VALIDATE STRUCTURE CASCADE FAST;

You can specify that you want to perform structure validation online while DML is occurring against the object being validated. There can be a slight performance impact when validating with ongoing DML affecting the object, but this is offset by the flexibility of being able to perform ANALYZE online. The following statement validates the emp table and all associated indexes online:

ANALYZE TABLE emp VALIDATE STRUCTURE CASCADE ONLINE;