Open Bug 419971 Opened 17 years ago Updated 2 years ago

64 characters is too long for a custom field name (Index name length limits)

Categories

(Bugzilla :: Bugzilla-General, defect, P3)

3.0.3
defect

Tracking

()

People

(Reporter: mkanat, Unassigned)

Details

Attachments

(1 file)

When you try to create a drop-down field with a 64-character name, you get the following error, on MySQL: DBD::mysql::db do failed: Identifier name 'cf_one_of_those_fields_with_a_long_name_quite_long_really_i_see_value_idx' is too long [for Statement "CREATE UNIQUE INDEX `cf_one_of_those_fields_with_a_long_name_quite_long_really_i_see_value_idx` ON cf_one_of_those_fields_with_a_long_name_quite_long_really_i_see (value)"] at Bugzilla/DB.pm line 595 We should probably limit them to something more like 32 or 40 characters, which would give us more space for things like this.
Version: 3.1.2 → 3.0.3
(In reply to comment #0) > We should probably limit them to something more like 32 or 40 characters Is this limitation set by Bugzilla or MySQL itself? If it's MySQL, what's the hard limit for index names? What about Pg and Oracle?
The limit is set for MySQL. I don't know the limit for Pg, but I could find out. Oracle has a very tiny limit (something like 32 characters) so we worked around the limit globally by md5-hashing all index names before creating them.
The Bugzilla 3.0 branch is now locked to security bugs and dataloss fixes only. This bug doesn't fit into one of these two categories and is retargetted to 3.2 as part of a mass-change. To catch bugmails related to this mass-change, use lts081207 in your email client filter.
Target Milestone: Bugzilla 3.0 → Bugzilla 3.2
Bugzilla 3.2 is restricted to security bugs only. Moreover, this bug is either assigned to nobody or got no traction for several months now. Rather than retargetting it at each new release, I'm clearing the target milestone and the bug will be retargetted to some sensible release when someone starts fixing this bug for real (Bugzilla 3.8 more likely).
Target Milestone: Bugzilla 3.2 → ---
Priority: -- → P3
Target Milestone: --- → Bugzilla 3.8
Target Milestone: Bugzilla 4.0 → ---
Assignee: general → koosha.khajeh
Target Milestone: --- → Bugzilla 4.4
Attached patch patch - v1Splinter Review
Attachment #638473 - Flags: review?(glob)
Attachment #638473 - Flags: review?(LpSolit)
Comment on attachment 638473 [details] [diff] [review] patch - v1 As usually, editing DB/Schema.pm is not enough. You must also fix existing installations. Also, I still want an answer to my question in comment 1 before going further.
Attachment #638473 - Flags: review?(glob)
Attachment #638473 - Flags: review?(LpSolit)
Attachment #638473 - Flags: review-
Status: NEW → ASSIGNED
We are going to branch for Bugzilla 4.4 next week and this bug is too invasive or too risky to be accepted for 4.4 at this point. The target milestone is set to 5.0 which is our next major release. I ask the assignee to reassign the bug to the default assignee if you don't plan to work on this bug in the near future, to make it clearer which bugs should be fixed by someone else on time for 5.0.
Target Milestone: Bugzilla 4.4 → Bugzilla 5.0
Assignee: koosha.khajeh → general
Status: ASSIGNED → NEW
Target Milestone: Bugzilla 5.0 → ---
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: