Duplicate entry for key 'PRIMARY' webERP version 4.15.2 - Printable Version +- webERP Forum (http://www.weberp.org/forum) +-- Forum: webERP Discussion (http://www.weberp.org/forum/forumdisplay.php?fid=1) +--- Forum: Problems / Bugs? (http://www.weberp.org/forum/forumdisplay.php?fid=8) +--- Thread: Duplicate entry for key 'PRIMARY' webERP version 4.15.2 (/showthread.php?tid=9290) |
Duplicate entry for key 'PRIMARY' webERP version 4.15.2 - wissedenis22 - 02-25-2023 I guess everything starts from table systypes, and if column typeno is not updated correctly it'll let to duplicate entry for whatever key. When I installed/upgraded to version 4.15.2 most accounts couldn't be update, I took a look to the systypes tables and I found out that all typeno where updated back to 0 and under SQL_CommonFunctions.inc line 19 PHP Code: $SQL = "UPDATE systypes SET typeno = typeno + 1 WHERE typeid = '" . $TransType . "'"; increments any primary ID of a give account ID (typename), however I don't get it why that when I ran the upgrade all my typeno was updated to back to 0, Hence facing Duplicate entry for key 'PRIMARY' for almost everything RE: Duplicate entry for key 'PRIMARY' webERP version 4.15.2 - dalescott - 03-14-2023 Unfortunately I don't have any tips, but I can say I upgraded a site to 4.15.2 without issue (the site was running pre-4.15.2 code that was pulled from git and not modified). |