I have a Distro
Current PBX Version:14.0.1rc1.17
Current System Version:12.7.2-1611-2.sng7
I currently have an issue where I need to upgrade my FreePBX Framework from 14.0.1rc1.17 to 14.0.1.20
I have tried from the gui and it just crashes. Nastily broken screens.
I try from CLI with commands like
fwconsole ma --edge upgrade framework
and I get this error. Zap 2 Dahdi compatible thing.
I guess I need to find this in the script and delete it?
[Doctrine\DBAL\Exception\UniqueConstraintViolationException]
An exception occurred while executing ‘ALTER TABLE freepbx_settings ADD PRIMARY KEY (keyword)’:
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘ZAP2DAHDICOMPAT’ for key ‘PRIMARY’
create table deduped_freepbx_settings like freepbx_settings;
INSERT deduped_freepbx_settings SELECT * FROM freepbx_settings GROUP BY keyword;
RENAME TABLE freepbx_settings TO freepbx_settings_with_dupes;
RENAME TABLE deduped_freepbx_settings TO freepbx_settings;
ALTER TABLE freepbx_settings ADD PRIMARY KEY (keyword);
create table deduped_module_xml like module_xml;
INSERT deduped_module_xml SELECT * FROM module_xml GROUP BY id;
RENAME TABLE module_xml TO module_xml_with_dupes;
RENAME TABLE deduped_module_xml TO module_xml;
ALTER TABLE module_xml ADD PRIMARY KEY (id);