Skip to content

Commit

Permalink
FIX Erreur SQL DB_ERROR_1170 BLOB/TEXT column 'url' used in key
Browse files Browse the repository at this point in the history
specification without a key length
  • Loading branch information
hregis committed Jul 26, 2024
1 parent fa70007 commit 59b6802
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions htdocs/install/mysql/migration/19.0.0-20.0.0.sql
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,10 @@ INSERT INTO llx_c_revenuestamp(rowid,fk_pays,taux,revenuestamp_type,note,active)

ALTER TABLE llx_hrm_evaluation ADD COLUMN entity INTEGER DEFAULT 1 NOT NULL;

-- Erreur SQL DB_ERROR_1170 BLOB/TEXT column 'url' used in key specification without a key length
ALTER TABLE llx_menu DROP INDEX idx_menu_uk_menu;
ALTER TABLE llx_menu MODIFY COLUMN url TEXT NOT NULL;
ALTER TABLE llx_menu ADD UNIQUE INDEX idx_menu_uk_menu (menu_handler, fk_menu, position, entity);

UPDATE llx_c_units SET short_label = 'mn' WHERE short_label = 'i' AND code = 'MI';

Expand Down
4 changes: 3 additions & 1 deletion htdocs/install/mysql/tables/llx_menu.key.sql
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,7 @@

ALTER TABLE llx_menu ADD INDEX idx_menu_menuhandler_type (menu_handler, type);

ALTER TABLE llx_menu ADD UNIQUE INDEX idx_menu_uk_menu (menu_handler, fk_menu, position, url, entity);
-- Erreur SQL DB_ERROR_1170 BLOB/TEXT column 'url' used in key specification without a key length

-- ALTER TABLE llx_menu ADD UNIQUE INDEX idx_menu_uk_menu (menu_handler, fk_menu, position, url, entity);
ALTER TABLE llx_menu ADD UNIQUE INDEX idx_menu_uk_menu (menu_handler, fk_menu, position, entity);

0 comments on commit 59b6802

Please sign in to comment.