[Django] #33671: Migrations crashes when adding/altering collations on indexed columns on Oracle.

17 views
Skip to first unread message

Django

unread,
Apr 29, 2022, 2:24:01 PM4/29/22
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
-------------------------------------+-------------------------------------
Reporter: Mariusz | Owner: nobody
Felisiak |
Type: Bug | Status: new
Component: | Version: 4.0
Migrations |
Severity: Normal | Keywords: oracle collation
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
Migrations crashes when adding/altering collations on indexed columns on
Oracle:
{{{
ORA-43923: The column cannot be modified to the specified collation.
}}}

Primary keys are handled in [https://github.com/django/django/pull/15642
PR]. Fields with indexes defined via `db_index=True`, `Meta.indexes`,
`Meta.constraints`, and `unique=True` are still affected.

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

Django

unread,
Apr 29, 2022, 3:44:41 PM4/29/22
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+--------------------------------------
Reporter: Mariusz Felisiak | Owner: nobody
Type: Bug | Status: new
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------

Comment (by GitHub <noreply@…>):

In [changeset:"1b3a949ba26ca8fefde7fa224e11c4aadbbdd724" 1b3a949b]:
{{{
#!CommitTicketReference repository=""
revision="1b3a949ba26ca8fefde7fa224e11c4aadbbdd724"
Refs #33671 -- Fixed migrations crash when adding collation to a primary
key on Oracle.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:1>

Django

unread,
May 3, 2022, 2:53:09 AM5/3/22
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+------------------------------------
Reporter: Mariusz Felisiak | Owner: nobody
Type: Bug | Status: new
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+------------------------------------
Changes (by Carlton Gibson):

* stage: Unreviewed => Accepted


--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:2>

Django

unread,
Mar 19, 2023, 2:52:43 PM3/19/23
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+------------------------------------
Reporter: Mariusz Felisiak | Owner: nobody
Type: Bug | Status: new
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+------------------------------------

Comment (by Durval Carvalho):

Since this issue has been resolved in PR #15642 and PR #15629, I am going
to close this ticket.

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:3>

Django

unread,
Mar 19, 2023, 2:52:57 PM3/19/23
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+------------------------------------
Reporter: Mariusz Felisiak | Owner: nobody
Type: Bug | Status: closed
Component: Migrations | Version: 4.0
Severity: Normal | Resolution: fixed

Keywords: oracle collation | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+------------------------------------
Changes (by Durval Carvalho):

* status: new => closed
* resolution: => fixed


--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:4>

Django

unread,
Mar 19, 2023, 3:00:24 PM3/19/23
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+------------------------------------
Reporter: Mariusz Felisiak | Owner: nobody
Type: Bug | Status: new

Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+------------------------------------
Changes (by Mariusz Felisiak):

* status: closed => new
* resolution: fixed =>


Comment:

Please don't close unresolved tickets. Have you checked the ticket
description?
> Primary keys are handled in ​PR. Fields with indexes defined via


`db_index=True`, `Meta.indexes`, `Meta.constraints`, and `unique=True` are
still affected.

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:5>

Django

unread,
Apr 4, 2024, 7:13:16 PM4/4/24
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+----------------------------------------
Reporter: Mariusz Felisiak | Owner: Mahesh Gupta
Type: Bug | Status: assigned
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+----------------------------------------
Changes (by Mahesh Gupta):

* owner: nobody => Mahesh Gupta
* status: new => assigned

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:6>

Django

unread,
Apr 5, 2024, 3:19:17 AM4/5/24
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+----------------------------------------
Reporter: Mariusz Felisiak | Owner: Mahesh Gupta
Type: Bug | Status: assigned
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+----------------------------------------
Changes (by Mahesh Gupta):

* has_patch: 0 => 1

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:7>

Django

unread,
Apr 5, 2024, 3:20:13 AM4/5/24
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+----------------------------------------
Reporter: Mariusz Felisiak | Owner: Mahesh Gupta
Type: Bug | Status: assigned
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+----------------------------------------
Comment (by Mahesh Gupta):

Opened PR https://github.com/django/django/pull/18049
--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:8>

Django

unread,
Apr 6, 2024, 9:19:58 AM4/6/24
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+----------------------------------------
Reporter: Mariusz Felisiak | Owner: Mahesh Gupta
Type: Bug | Status: assigned
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
----------------------------------+----------------------------------------
Changes (by Mariusz Felisiak):

* needs_better_patch: 0 => 1

--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:9>

Django

unread,
Apr 8, 2024, 4:19:16 PM4/8/24
to django-...@googlegroups.com
#33671: Migrations crashes when adding/altering collations on indexed columns on
Oracle.
----------------------------------+----------------------------------------
Reporter: Mariusz Felisiak | Owner: Mahesh Gupta
Type: Bug | Status: assigned
Component: Migrations | Version: 4.0
Severity: Normal | Resolution:
Keywords: oracle collation | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
----------------------------------+----------------------------------------
Comment (by Mahesh Gupta):

As per https://docs.oracle.com/en/error-help/db/ora-43923/ Collation are
divided into groups and
Group 1: BINARY, USING_NLS_COMP, USING_NLS_SORT, USING_NLS_SORT_CS,
USING_NLS_SORT_VAR1, and USING_NLS_SORT_VAR1_CS
Group 2: BINARY_CI, USING_NLS_SORT_CI, and USING_NLS_SORT_VAR1_CI
Group 3: BINARY_AI, USING_NLS_SORT_AI, and USING_NLS_SORT_VAR1_AI
and action suggested by Oracle is
When modifying the column collation, specify a new collation that is in
the same group as the current column collation. If there is no current
collation, because you changed the column data type at the same time and
the old data type is not a character data type, then select a collation
from Group 1 as the new collation.

Reading this, should we really fix this or this is more of a user error
and they should act accordingly?
--
Ticket URL: <https://code.djangoproject.com/ticket/33671#comment:10>
Reply all
Reply to author
Forward
0 new messages