General developer forum


Picture of Paul Kelly

I want to use the web service to mark a lesson complete.  I tried using mod_assign_view_assign.  I got an error message, "dml_missing_record_exception".  I got a trace of the SQL statements that Moodle is running to mark a lesson complete.  The error message happens when it tries to do a SELECT from the moodle.mdl_assign table.  There are no records in this table.  I do have a course and a lesson within Moodle.  And, the lesson I use for within the select is within the lesson table.  The token used in the web service GET is valid also.  I used the token in another web service function.  Any ideas as to why mod_assign_view_assign is not working?  Here's what the url looks like:


Average of ratings: -
Re: mod_assign_view_assign
Group Particularly helpful Moodlers

Not quite sure why calling a function belonging to a student assignment is relevant to marking a lesson complete.

If you have a look at the code on /local/mobile/db/services.php you can find a list of web services that the mobile app can call for example.

There are 4 web services that might be more relevant:


In particular the update activity completion status manually looks interesting.

If you call that web service the code in /completion/classes/external.php function you might have better results


If you aren't trying to complete an activity manually, sorry, please explain what you are trying to achieve.

Average of ratings: -