Fix Error on the uk_links index of the llx_links table #25926

This commit is contained in:
Francis Appels 2023-09-25 17:17:52 +02:00
parent a68b00de4e
commit 94dadee77f
2 changed files with 7 additions and 1 deletions

View File

@ -113,3 +113,9 @@ UPDATE llx_societe_account SET site = 'dolibarr_website' WHERE fk_website > 0 AN
ALTER TABLE llx_societe_account MODIFY COLUMN site varchar(128) NOT NULL;
ALTER TABLE llx_accounting_account MODIFY COLUMN pcg_type varchar(32);
-- Drop the composite unique index that exists on llx_links to rebuild a new one with objecttype included.
-- The old design did not allow same label on different object with same id.
-- VMYSQL4.1 DROP INDEX uk_links on llx_links;
-- VPGSQL8.2 DROP INDEX uk_links;
ALTER TABLE llx_links ADD UNIQUE INDEX uk_links (objectid, objecttype,label);

View File

@ -18,5 +18,5 @@
-- Linked files
-- ========================================================================
ALTER TABLE llx_links ADD UNIQUE INDEX uk_links (objectid,label);
ALTER TABLE llx_links ADD UNIQUE INDEX uk_links (objectid, objecttype, label);