Error when show submitted assignments

Error when show submitted assignments

by Beth Ludojoski -
Number of replies: 1

Hello,
I have a Moodle 2.0.1 (Build: 20101225).

Last week the server updated MySql and the assigment activities are not working anymore.

Here I copy the message. Really need help to solve this. Hope anyone can help me.

--------------------
Error reading from database

Debug info: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'edu_user u LEFT JOIN edu_assignment_submissions s ON u.id = s.userid
' at line 4
SELECT u.id,u.picture,u.firstname,u.lastname,u.imagealt,u.email,
s.id AS submissionid, s.grade, s.submissioncomment,
s.timemodified, s.timemarked,
COALESCE(SIGN(CAST(s.timemarked as SIGNED) + SIGN(CAST(s.timemarked as SIGNED) - CAST(s.timemodified as SIGNED))), 0) AS statusFROM edu_user u LEFT JOIN edu_assignment_submissions s ON u.id = s.userid
AND s.assignment = 342 WHERE u.id IN (8886,3726,7885,8996,7569,4913,7139,4911,4912,3509,4715,7888,4726,3689,7890,6802,4879,4727,4725,4717,4719,4724,4718,4723,5596,8768,8887,4716,2848,4720,4722,4721,8995,2451,4874,7566,8885,7567,7568,7140,5597,5594,4728,4793,4875,6424,7886,5593,6425,4876,4877,4878,1883,7565,5595,7138,7137,8496,6423,4761,4762,4763,4764,4765,4766,4767,4768,4769,4770,5300,7887,9009,9010,9011,9014,9013) ORDER BY lastname ASC
[array (
)]
Stack trace:
  • line 391 of /lib/dml/moodle_database.php: dml_read_exception thrown
  • line 769 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
  • line 1303 of /mod/assignment/lib.php: call to mysqli_native_moodle_database->get_records_sql()
  • line 642 of /mod/assignment/lib.php: call to assignment_base->display_submissions()
  • line 57 of /mod/assignment/submissions.php: call to assignment_base->submissions()


Trank you, very much,
Beth


Average of ratings: -
In reply to Beth Ludojoski

Re: Error when show submitted assignments

by Yael Z -

Hi Beth!

There is a space missing between "status" and "FROM" on line 4.

Go to:

line 57 of /mod/assignment/submissions.php: call to assignment_base->submissions() And see if you can add a space.

Yael - Developer in OpenApp