Commit 3480cf1a authored by Markus Klein's avatar Markus Klein Committed by Andreas Fernandez
Browse files

[TASK] Sane index length for "uid_foreign_tablefield"

The index lengths for the fields "tablenames" and "fieldname"
of table "sys_category_record_mm" are way too big.
It suffices to have only few significant characters in the index.

We only take the first 40 characters of the tablename and the first
three characters of the fieldname as those should already be
distinctive enough to have a high quality index.
Assuming most table names are below 40 characters anyway and usually
only a few fields per table will be a category.

Resolves: #66773
Releases: master
Change-Id: Ib1f077c93425992c557fbc4457699d867521a3ba

Reviewed-by: Stephan Großberndt's avatarStephan Großberndt <>
Reviewed-by: Stefan Froemken's avatarStefan Froemken <>
Tested-by: Stefan Froemken's avatarStefan Froemken <>
Reviewed-by: Andreas Fernandez's avatarAndreas Fernandez <>
Tested-by: Andreas Fernandez's avatarAndreas Fernandez <>
parent 3183decd
...@@ -689,5 +689,5 @@ CREATE TABLE sys_category_record_mm ( ...@@ -689,5 +689,5 @@ CREATE TABLE sys_category_record_mm (
sorting_foreign int(11) DEFAULT '0' NOT NULL, sorting_foreign int(11) DEFAULT '0' NOT NULL,
KEY uid_local_foreign (uid_local,uid_foreign), KEY uid_local_foreign (uid_local,uid_foreign),
KEY uid_foreign_tablefield (uid_foreign,tablenames,fieldname,sorting_foreign) KEY uid_foreign_tablefield (uid_foreign,tablenames(40),fieldname(3),sorting_foreign)
); );
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment