SQLite | Index | Dropping an Index
This article explains how to drop an existing index.
Dropping an Existing Index
Use the DROP INDEX statement to drop an existing index. The syntax is as follows.
DROP INDEX index_name;
Let’s drop an index. Before doing so, use the SQLite .indices command to list the existing indexes.
.indices
sqlite> .indices
nameindex
sqlite>
Run the following statement to drop the nameindex index.
drop index nameindex;
sqlite> drop index nameindex;
sqlite>
Run .indices again to verify that the nameindex index has been dropped.
.indices
sqlite> .indices
sqlite>
The empty result confirms that the nameindex index has been dropped.