quiz_attempts

0 rows


Description

Stores users attempts at quizzes.

Columns

Column Type Size Nulls Auto Default Children Parents Comments
id BIGINT 19 √ null

Standard Moodle primary key.

quiz BIGINT 19 0
quiz.id quizatte_qui2_fkR

Foreign key reference to the quiz that was attempted.

userid BIGINT 19 0
user.id quizatte_use2_fkR

Foreign key reference to the user whose attempt this is.

attempt MEDIUMINT 7 0

Sequentially numbers this student’s attempts at this quiz.

uniqueid BIGINT 19 0
question_usages.id quizatte_uni_fkR

Foreign key reference to the question_usage that holds the details of the the question_attempts that make up this quiz attempt.

layout LONGTEXT 2147483647 null
currentpage BIGINT 19 0
preview SMALLINT 5 0
state VARCHAR 16 inprogress

The current state of the attempts. ‘inprogress’, ‘overdue’, ‘finished’ or ‘abandoned’.

timestart BIGINT 19 0

Time when the attempt was started.

timefinish BIGINT 19 0

Time when the attempt was submitted. 0 if the attempt has not been submitted yet.

timemodified BIGINT 19 0

Last modified time.

timemodifiedoffline BIGINT 19 0

Last modified time via web services.

timecheckstate BIGINT 19 √ 0

Next time quiz cron should check attempt for state changes. NULL means never check.

sumgrades DECIMAL 10,5 √ null

Total marks for this attempt.

gradednotificationsenttime BIGINT 19 √ null

The timestamp when the ‘graded’ notification was sent.

Indexes

Constraint Name Type Sort Column(s)
PRIMARY Primary key Asc id
quizatte_qui2_ix Performance Asc quiz
quizatte_quiuseatt2_uix Must be unique Asc/Asc/Asc quiz + userid + attempt
quizatte_statim2_ix Performance Asc/Asc state + timecheckstate
quizatte_uni2_uix Must be unique Asc uniqueid
quizatte_use2_ix Performance Asc userid

Relationships