ALTER TABLE llx_ecmtiers_dir_rights ADD  rowid integer(11) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST;
ALTER TABLE llx_ecmtiers_file_rights ADD  rowid integer(11) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST;
ALTER TABLE llx_ecmtiers_dir_rights ADD UNIQUE idx_fk_user_fk_dir ( fk_user_id , fk_dir );
ALTER TABLE llx_ecmtiers_file_rights ADD UNIQUE `idx_fk_user_fk_file` ( fk_user_id , fk_file );
ALTER TABLE llx_ecmtiers_directories ADD projetid integer(11) DEFAULT 0;
ALTER TABLE llx_ecmtiers_documents ALTER ref SET DEFAULT NULL;
ALTER TABLE llx_ecmtiers_documents ALTER filemime SET DEFAULT NULL;