Upgrading to Questionnaire 2.9 introduced problems in database schema

Re: Upgrading to Questionnaire 2.9 introduced problems in database schema

by Séverin Terrier -
Number of replies: 2
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

Hi,

Problems corrected by launching these SQL queries:

ALTER TABLE mdl_questionnaire_survey MODIFY COLUMN feedbackscores TINYINT(1) NOT NULL DEFAULT 0;
ALTER TABLE mdl_questionnaire_feedback MODIFY COLUMN feedbacklabel varchar(50) NULL;

Séverin

Average of ratings: Useful (1)
In reply to Séverin Terrier

Re: Upgrading to Questionnaire 2.9 introduced problems in database schema

by Yael Z -

Hi,

Indeed there is a mismatch in the plugin upgrade,

If you install the Questionnaire for the first time then the 'feedbackscores' column is created correctly- and doesn't allow nulls. (It is created using the Install.xml)

Though, if you upgrade it from an older version, then the column is created in the upgrade.php file and it allows null values.

This caused us a problem when trying to restore courses from a different site that upgraded the Questionnaire to a site that had a clean installation of the same version,

the null values couldn't be inserted on the clean installation. that were inserted in the first site.

This should really be fixed in the Questionnaire.

Y Z Developer in OpenApp

In reply to Yael Z

Re: Upgrading to Questionnaire 2.9 introduced problems in database schema

by Mike Churchward -
Picture of Core developers Picture of Plugin developers Picture of Testers

Best way to deal with these is to create an issue in the tracker.

I have created CONTRIB-6445 for this issue.

mike