I'm running Moodle 3.10.
I was having some errors related to a UTF mismatch, so I ran a command on the database, which seemed to fix the error. (This is the command: $ php admin/cli/mysql_collation.php --collation=utf8mb4_unicode_ci )
Then my problem was fixed!
However, I then went to upgrade a plugin, and now I'm getting this error:
Upgrading to new version
DDL sql execution error
CREATE TABLE mdl_block_recent_activity (
id BIGINT(10) NOT NULL auto_increment,
courseid BIGINT(10) NOT NULL,
cmid BIGINT(10) NOT NULL,
timecreated BIGINT(10) NOT NULL,
userid BIGINT(10) NOT NULL,
action TINYINT(1) NOT NULL,
modname VARCHAR(20) COLLATE utf8mb4_unicode_ci,
CONSTRAINT PRIMARY KEY (id)
, KEY mdl_blocreceacti_coutim2_ix (courseid, timecreated)
ENGINE = InnoDB
DEFAULT COLLATE = utf8mb4_unicode_ci ROW_FORMAT=Compressed
COMMENT='Recent activity block'
Error code: ddlexecuteerror
I've read some forum posts that suggest I might be able to drop the table mdl_block_recent_activity, but of course, that makes me a little nervous. (Yes, I would back up the database first, of course.) Though the data in there doesn't seem to be super-vital to the course. Related--could I just rename the table temporarily, to something like old_block_recent_activity instead?
I'll admit that this is a little confusing, since I would think that yes, of course this table already exists. Is the upgrade script trying to create a new version of it with my new character set?
Any pointers would be welcome.
Thanks in advance.