Fragmentation - Lab Exercise

Fragmentation - Lab Exercise
Practice questions
    1)create a table like all_objects  on a newly created tablespace (eg. Tbs)
    
    2)alter the table and add an extra column as “aoid”
    
    3)create an index and primary key on column “aoid”
    
    4)create composite index on (owner, object_id)
    
    5)create a sequence to generate values for the column “aoid”
    
    6)All other data to be inserted from all_objects(upto 1lak records) and check table size , index size
    
    7)check number of extents, number of blocks of tables and indexes
    
    8)delete from table where rownum < 50000 and check table size , index size
    
    9)check number of extents, number of blocks of tables and indexes
    
    10)the size will remain the same, explain why?
    
    11)check the fragmentation for table, index
    
    12)de-fragment using move query
    
    13)check the index status and table size and index size
    
    14)check number of extents, number of blocks of tables and indexes
    
    15)insert more records (upto 1 lakh) and check table size and index size
    
    16)check number of extents, number of blocks of tables and indexes
    
    17)delete from table where rownum < 50000 and check table size , index size
    
    18)check number of extents, number of blocks of tables and indexes
    
    19)check the fragmentation for table, index
    
    20)defragment the table using shrink query
    
    21)insert more records (upto 1 lakh) and check table size , index size
    
    22)check number of extents, number of blocks of tables and indexes
    
    23)delete from table where rownum < 50000 and check table size , index size
    
    24)check number of extents, number of blocks of tables and indexes
    
    25)check the fragmentation for table, index
    
    26)defragment the table online redefinition
    
    27)change the invalid objects to valid state