summaryrefslogtreecommitdiff
path: root/django/db/backends/mysql/features.py
diff options
context:
space:
mode:
authorDavid Wobrock <david.wobrock@gmail.com>2022-05-02 17:22:54 +0200
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2022-05-12 20:44:03 +0200
commiteacd4977f6a4bb038e82796ba79a2f61bae330c6 (patch)
tree8d9b1c7d18226a8922826257ed997cee6229af10 /django/db/backends/mysql/features.py
parent20e65a34aea0ace077033c84854dcf225e248f8c (diff)
downloaddjango-eacd4977f6a4bb038e82796ba79a2f61bae330c6.tar.gz
Refs #27064 -- Added RenameIndex migration operation.
Diffstat (limited to 'django/db/backends/mysql/features.py')
-rw-r--r--django/db/backends/mysql/features.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/django/db/backends/mysql/features.py b/django/db/backends/mysql/features.py
index 7b9a90ab06..1261d9e9a6 100644
--- a/django/db/backends/mysql/features.py
+++ b/django/db/backends/mysql/features.py
@@ -344,3 +344,9 @@ class DatabaseFeatures(BaseDatabaseFeatures):
and self._mysql_storage_engine != "MyISAM"
and self.connection.mysql_version >= (8, 0, 13)
)
+
+ @cached_property
+ def can_rename_index(self):
+ if self.connection.mysql_is_mariadb:
+ return self.connection.mysql_version >= (10, 5, 2)
+ return True