Uploaded image for project: 'FreePBX'
  1. FreePBX
  2. FREEPBX-19539

cxpanel SQL Error

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 13, 14, 15
    • Fix Version/s: 13, 14, 15
    • Component/s: iSymphony
    • Labels:
      None
    • Sprint:
      Sprint 4!
    • ToDo:
    • Distro Version:
      Ubuntu 18.04.02 - MySQL Server 5.7.25-0ubuntu0.18.04.2 (Ubuntu)
    • Module Fix Version:

      Description

      When updating to cxpanel 14.0.2:

      
      In install.php line 417:  SQLSTATE[HY000]: General error: 1364 Field 'auto_answer' doesn't have a default value 

      Doing a 'show create table cxpanel_users' confirms this:

      
      CREATE TABLE `cxpanel_users` (
        `cxpanel_user_id` int(11) NOT NULL AUTO_INCREMENT,
        `user_id` varchar(190) COLLATE utf8mb4_unicode_ci NOT NULL,
        `display_name` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
        `peer` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
        `add_extension` int(11) NOT NULL,
        `full` int(11) NOT NULL,
        `add_user` int(11) NOT NULL,
        `hashed_password` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
        `initial_password` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
        `auto_answer` int(11) NOT NULL,
        `parent_user_id` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
        `password_dirty` int(11) NOT NULL,
        PRIMARY KEY (`cxpanel_user_id`),
        UNIQUE KEY `user_id` (`user_id`)
      ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci 
      

      This may be a compatibility issue, but I can't find anything that ever said there WAS a default vaule, or, that null was allowed.

      After editing install.php to add a default to auto_answer, it's also erroring on password_dirty.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                jfinstrom James Finstrom
                Reporter:
                xrobau Rob Thomas
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  NextupJiraPlusStatus

                  Error rendering 'slack.nextup.jira:nextup-jira-plus-status'. Please contact your Jira administrators.