Record of issued certificates go missing on upgrade

Record of issued certificates go missing on upgrade

by Leon Erasmus -
Number of replies: 5

Hallo,

I have upgraded from Moodle 1.9 to Moodle 2.2 on a test installation. On the test installation (2.2) I have to individually add the certificate activity to each course since this is not carried over when I upgrade. A side effect of this is that the records of all previously issued certificates also disappears. I know I can use the 'download in Excel format' option before I upgrade, but that still leaves no record on the new installation. Has anybody ideas around this?

Kind regards, Leon

Average of ratings: -
In reply to Leon Erasmus

Re: Record of issued certificates go missing on upgrade

by Mark Nelson -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Hi Leon,

The upgrade should not delete the certificate activities from the courses. If the course activities were deleted and had to be manually added again not many people would be willing to upgrade to the latest version of Moodle! Moodle stores the location of modules in courses in a separate database table, which the certificate upgrade code does not touch.

I don't see why the upgrade would delete the certificate activities from the courses. Is it just for the certificate activity?

Regards,

Mark

In reply to Mark Nelson

Re: Record of issued certificates go missing on upgrade

by Daniel Krause -

Hi Mark

 

When performing the upgrade I get the following error if i leave the certificate module installed.

Debug info: Illegal mix of collations (utf8_unicode_ci,IMPLICIT) and (utf8_general_ci,IMPLICIT) for operation '='
SELECT DISTINCT c.id AS courseid, ra.enrol, c.timecreated, c.timemodified
FROM mdl_course c
JOIN mdl_context ctx ON (ctx.instanceid = c.id AND ctx.contextlevel = 50)
JOIN mdl_role_assignments ra ON (ra.contextid = ctx.id AND ra.enrol <> '')
LEFT JOIN mdl_enrol e ON (e.courseid = c.id AND e.enrol = ra.enrol)
WHERE c.id <> ? AND e.id IS NULL
[array (
0 => '1',
)]
Stack trace:
  • line 394 of /lib/dml/moodle_database.php: dml_read_exception thrown
  • line 768 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
  • line 4051 of /lib/db/upgrade.php: call to mysqli_native_moodle_database->get_recordset_sql()
  • line 1406 of /lib/upgradelib.php: call to xmldb_main_upgrade()
  • line 236 of /admin/index.php: call to upgrade_core()

 

I cannot upgrade the certificate module on moodle 1.9.8 as the newer one is not compatible, and cannot upgrade with it still installed, the only method I found that worked was to uninstall the module, then upgrade to 2.2.2 and then reinstall the latest module.

If there is a better method please let me know

Regards

Daniel

In reply to Daniel Krause

Re: Record of issued certificates go missing on upgrade

by Leon Erasmus -

This is the error we get when upgrading the certificate module on Moodle 1.9.8:

Module "certificate" (2011110106) could not be installed. It requires a newer version of Moodle (currently you are using 2007101580, you need 2011070101).

In reply to Leon Erasmus

Re: Record of issued certificates go missing on upgrade

by Daniel Krause -

Problem solved.

When upgrading from 1.9.8, I did not brng across the certificate folder, only after i had upgraded to 2.2.2 did i think exctract the new module and all seems fine now

In reply to Daniel Krause

Re: Record of issued certificates go missing on upgrade

by Daniel Krause -

Sorry that was the incorrect error message.