Check and alter Table Index Parallel degree

Check and alter Table Index Parallel degree

1. Check the Degree of Tables in Oracle Enterprise Edition.

set line 200 pages 200
col table_name for a25
select table_name, degree from dba_tables where owner='HR';

2. Change the Degree of Parallelism at Table Level.

alter table owner.table_name parallel (degree 4);

3. Check the degree of indexes of particular table.

select index_name,degree from dba_indexes where table_name='EMPLOYEES';

4. Modify the degree of indexes.

Alter index owner.index_name parallel (degree 4);

5. Change the index degree for all the index present in one table.

select 'alter index '||owner||'.'||index_name||' parallel (degree 4);' from dba_indexes where table_name='EMPLOYEES';

6. Change the table degree for all the tables in schema.

select 'alter table '||owner||'.'||table_name||' parallel (degree 4);' from dba_tables where owner='HR';

7. Change the index degree for all the indexes present in schema.

select 'alter index '||owner||'.'||index_name||' parallel (degree 4);' from dba_indexes where owner='HR';

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 )

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.