diff --git a/django/db/backends/mysql/introspection.py b/django/db/backends/mysql/introspection.py index 2c77f76ee3..e227f72706 100644 --- a/django/db/backends/mysql/introspection.py +++ b/django/db/backends/mysql/introspection.py @@ -42,7 +42,7 @@ def get_relations(cursor, table_name): except (ProgrammingError, OperationalError): # Fall back to "SHOW CREATE TABLE", for previous MySQL versions. # Go through all constraints and save the equal matches. - cursor.execute("SHOW CREATE TABLE %s" % table_name) + cursor.execute("SHOW CREATE TABLE %s" % quote_name(table_name)) for row in cursor.fetchall(): pos = 0 while True: