Enable an Function-Based Index

Enable an Function-Based Index example To enable an oracle database Function-Based index you must use the command alter index with ENABLE keyword. The status of index will change from disable to enable. — disable Index using ENABLE ALTER INDEX CITY_IDX ENABLE; Output: index CITY_IDX altered. Check indexes select INDEX_NAME, INDEX_TYPE, STATUS, FUNCIDX_STATUS from USER_INDEXES WHERE…(Continue Reading)

Disable an Function-Based Index

Disable an Function-Based Index example To disable an oracle database Function-Based index you must use the command alter index with DISABLE keyword. The status of index will change from enable to disable. — disable Index using DISABLE ALTER INDEX CITY_IDX DISABLE; Output: index CITY_IDX altered. Check indexes select INDEX_NAME, INDEX_TYPE, STATUS, FUNCIDX_STATUS from USER_INDEXES WHERE…(Continue Reading)

Enable an Index

Enable an Index example In Oracle database to enable an index you must use the command alter index with rebuild keyword. The status of index will change from unusable to valid. — enable Index using REBUILD ALTER INDEX STU_LN_IDX REBUILD; Output: index STU_LN_IDX altered. Check indexes select INDEX_NAME, INDEX_TYPE, STATUS from USER_INDEXES WHERE table_name=’STUDENTS_LIST’; Output:…(Continue Reading)

Disable an Index

Disable an Index example To disable an oracle database index you must use the command alter index with unusable keyword. The status of index will change from valid to unusable. — disable Index using UNUSABLE ALTER INDEX STU_LN_IDX UNUSABLE; Output: index STU_LN_IDX altered. Check indexes select INDEX_NAME, INDEX_TYPE, STATUS from USER_INDEXES WHERE table_name=’STUDENTS_LIST’; Output: INDEX_NAME…(Continue Reading)

Rename an Index

Rename Index example — rename Index ALTER INDEX STUDENT_IDX RENAME TO STUDENT_IDX_2; Output: index STUDENT_IDX altered. Check index select INDEX_NAME, INDEX_TYPE, TABLESPACE_NAME from USER_INDEXES WHERE table_name=’STUDENTS_LIST’; Output: INDEX_NAME INDEX_TYPE TABLESPACE_NAME STUDENT_IDX_2 NORMAL SYSTEM