Fix: [ bug #372 ] Upgrade error from 3.1.0 to 3.2.0 Beta

This commit is contained in:
Laurent Destailleur 2012-04-21 19:12:20 +02:00
parent 3a2caa3e46
commit 2b77a99fa3

View File

@ -213,9 +213,11 @@ ALTER TABLE llx_paiement ADD COLUMN entity integer DEFAULT 1 NOT NULL AFTER rowi
ALTER TABLE llx_product_price ADD COLUMN entity integer DEFAULT 1 NOT NULL AFTER rowid;
-- Restore foreign key (on llx_expedition_methode before) on correct table (llx_c_shipment_mode)
UPDATE llx_expedition SET fk_expedition_methode = null WHERE fk_expedition_methode NOT IN (SELECT rowid FROM llx_c_shipment_mode);
ALTER TABLE llx_expedition DROP FOREIGN KEY fk_expedition_fk_expedition_methode;
ALTER TABLE llx_expedition ADD CONSTRAINT fk_expedition_fk_expedition_methode FOREIGN KEY (fk_expedition_methode) REFERENCES llx_c_shipment_mode (rowid);
-- VMYSQL4.1 UPDATE llx_chargesociales set tms = date_creation WHERE tms = '0000-00-00 00:00:00';
ALTER TABLE llx_propal MODIFY fk_projet integer DEFAULT NULL;