Prepare a course with two editing teachers - say Teacher A and Teacher B
Login as the Teacher A and create a new Workshop activity
In the Workshop settings, enable "Use examples" feature
Define a simple assessment form for the workshop, add example submission and provide the reference assessment for the submission
Switch the workshop to the Submission phase
Still logged in as Teacher A, switch role to the Student
TEST: Try to assess the example submission. Make sure a message displays saying that you can't assess the example because you are the one who provided the example assessment.
Return to normal role and log in as the second Teacher B
Logged in as Teacher B, switch role to the Student again
TEST: Try to assess the example submission. Make sure that you can fill the assessment form, save it and then the normal comparison between the reference assessment and your assessment appears.

Description

When you (teacher/admin) switch to the student role and then click on the Assess button to see the "Example submissions to assess" you get the "Can not find data record in database table workshop_assessments." error. (see attachment)

Replication steps:

Create a new workshop activity

Set it up until you reach the Submission phase

As teacher/admin, switch to the student role

Click on the Assess button to see the "Example submissions to assess"

You get the "Can not find data record in database table workshop_assessments." error. (see attachment)

Michael de Raadt
added a comment - 16/Nov/11 10:58 AM Thanks for reporting that.
I've put that on the backlog.
In the meantime feel free to help us work on this issue. If you are able to provide a patch, please add a patch label so we will spot it.

Confirmed and fixed. The reason here is that the same person (user) can't provide the reference assessment and then try to assess the example submission (due to database scheme constraints).

Submitting a patch for the integration. The patchset consists of two patches. The first one just moves some $PAGE settings and the renderer initialization so that we can produce output in param handling sections of the code.

The second patch actually fixes this issue by displaying a nice message instead of throwing the error.

David Mudrák
added a comment - 25/Nov/11 11:09 PM Confirmed and fixed. The reason here is that the same person (user) can't provide the reference assessment and then try to assess the example submission (due to database scheme constraints).
Submitting a patch for the integration. The patchset consists of two patches. The first one just moves some $PAGE settings and the renderer initialization so that we can produce output in param handling sections of the code.
The second patch actually fixes this issue by displaying a nice message instead of throwing the error.