#23859: Renaming a field in a index_together fails
----------------------------+------------------------------------
     Reporter:  MarkusH     |                    Owner:  MarkusH
         Type:  Bug         |                   Status:  new
    Component:  Migrations  |                  Version:  1.7
     Severity:  Normal      |               Resolution:
     Keywords:              |             Triage Stage:  Accepted
    Has patch:  0           |      Needs documentation:  0
  Needs tests:  0           |  Patch needs improvement:  0
Easy pickings:  0           |                    UI/UX:  0
----------------------------+------------------------------------
Changes (by timgraham):

 * status:  closed => new
 * has_patch:  1 => 0
 * resolution:  fixed =>


Comment:

 This is causing a test failure on Oracle:
 {{{
 ======================================================================
 ERROR: test_rename_field (migrations.test_operations.OperationTests)
 ----------------------------------------------------------------------
 Traceback (most recent call last):
   File "/home/tim/code/django/tests/migrations/test_operations.py", line
 988, in test_rename_field
     project_state = self.set_up_test_model("test_rnfl",
 unique_together=True, index_together=True)
   File "/home/tim/code/django/tests/migrations/test_operations.py", line
 146, in set_up_test_model
     return self.apply_operations(app_label, ProjectState(), operations)
   File "/home/tim/code/django/tests/migrations/test_operations.py", line
 32, in apply_operations
     return migration.apply(project_state, editor)
   File "/home/tim/code/django/django/db/migrations/migration.py", line
 108, in apply
     operation.database_forwards(self.app_label, schema_editor,
 project_state, new_state)
   File "/home/tim/code/django/django/db/migrations/operations/models.py",
 line 36, in database_forwards
     schema_editor.create_model(model)
   File "/home/tim/code/django/django/db/backends/schema.py", line 266, in
 create_model
     self.execute(self._create_index_sql(model, fields, suffix="_idx"))
   File "/home/tim/code/django/django/db/backends/schema.py", line 102, in
 execute
     cursor.execute(sql, params)
   File "/home/tim/code/django/django/db/backends/utils.py", line 65, in
 execute
     return self.cursor.execute(sql, params)
   File "/home/tim/code/django/django/db/utils.py", line 95, in __exit__
     six.reraise(dj_exc_type, dj_exc_value, traceback)
   File "/home/tim/code/django/django/db/backends/utils.py", line 65, in
 execute
     return self.cursor.execute(sql, params)
   File "/home/tim/code/django/django/db/backends/oracle/base.py", line
 916, in execute
     return self.cursor.execute(query, self._param_generator(params))
 DatabaseError: ORA-01408: such column list already indexed
 }}}

--
Ticket URL: <https://code.djangoproject.com/ticket/23859#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.2c8fa6809e7ac24596108f82b589ec72%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to