Moodle 3.4 用户创建错误“dmlwriteexception”
Posted
技术标签:
【中文标题】Moodle 3.4 用户创建错误“dmlwriteexception”【英文标题】:Moodle 3.4 User creation error 'dmlwriteexception' 【发布时间】:2021-03-25 12:22:06 【问题描述】:我们已将 moodle 网站从 inmotion 托管迁移到安装在 EC2 上的新 cPanel/WHM。我们的数据库版本是 Mariadb 10.2,php 7.2(和以前一样)。但是在创建新用户时,无法写入数据库,出现dmlwriteexception
错误:
Debug info: FUNCTION db.CAP_FIRST does not exist
INSERT INTO mdl_user (username,auth,suspended,firstname,lastname,email,maildisplay,city,country,timezone,theme,imagealt,firstnamephonetic,lastnamephonetic,middlename,alternatename,url,icq,skype,aim,yahoo,msn,idnumber,institution,department,phone1,phone2,address,timemodified,description,descriptionformat,mnethostid,confirmed,timecreated,password,calendartype,mailformat,maildigest,autosubscribe,trackforums,lang) VALUES(
)
Error code: dmlwriteexception
Stack trace:
line 489 of /lib/dml/moodle_database.php: dml_write_exception thrown
line 1300 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
line 1346 of /lib/dml/mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->insert_record_raw()
line 107 of /user/lib.php: call to mysqli_native_moodle_database->insert_record()
line 188 of /user/editadvanced.php: call to user_create_user()
以前有人遇到过这个问题吗?
【问题讨论】:
不再支持 Moodle 3.4。如果可能,升级到 moodle 3.10 或 3.9 【参考方案1】:这是升级 moodle 站点时的常见问题,请将 dbcollation 更改为 'utf8_general_ci'
【讨论】:
以上是关于Moodle 3.4 用户创建错误“dmlwriteexception”的主要内容,如果未能解决你的问题,请参考以下文章
Moodle rest post返回错误,其功能为core_user_get_users_by_field