user509721
user509721

Reputation: 207

In Django, when setting db_index to false for a field or removing 'db_index=True', does the index for the field get removed?

If not, is the easiest way to remove it to manually remove the index tables through Django's dbshell?

This is for the purpose of load testing; I want to test the database with indexing turned on for on certain fields and test it without indexing for the same fields.

Upvotes: 1

Views: 356

Answers (1)

Thomas Orozco
Thomas Orozco

Reputation: 55303

Not automatically, you'll need to make a database migration to add or remove an index, you can use south for this purpose.

Upvotes: 1

Related Questions