Grade Items History Table Schema (grade_items_history)


Description

History of grade_items

grade_items_history table columns

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

created/modified/deleted constants

oldid BIGINT 19 null
grade_items.id graditemhist_old2_fk R
source VARCHAR 255 null

What caused the modification? manual/module/import/...

timemodified BIGINT 19 null

The last time this grade_item was modified

loggeduser BIGINT 19 null
user.id graditemhist_log2_fk R

the userid of the person who last modified this outcome

courseid BIGINT 19 null
course.id graditemhist_cou2_fk R

The course this item is part of

categoryid BIGINT 19 null
grade_categories.id graditemhist_cat2_fk R

(optional) the category group this item belongs to

itemname VARCHAR 255 null

The name of this item (pushed in by the module)

itemtype VARCHAR 30

'mod', 'blocks', 'import', 'calculated' etc

itemmodule VARCHAR 30 null

'forum', 'quiz', 'csv', etc

iteminstance BIGINT 19 null

id of the item module

itemnumber BIGINT 19 null

Can be used to distinguish multiple grades for an activity

iteminfo LONGTEXT 2147483647 null

Info and notes about this item XXX

idnumber VARCHAR 255 null

Arbitrary idnumber provided by the module responsible

calculation LONGTEXT 2147483647 null

Formula describing how to derive this grade from other items, referring to them using giXXX where XXX is grade item id ... eg something like: =sin(square(#gi20#)) + #gi30#

gradetype SMALLINT 5 1

0 = none, 1 = value, 2 = scale, 3 = text

grademax DECIMAL 10,5 100.00000

What is the maximum allowable grade?

grademin DECIMAL 10,5 0.00000

What is the minimum allowable grade?

scaleid BIGINT 19 null
scale.id graditemhist_sca2_fk R

If this grade is based on a scale, which one is it?

outcomeid BIGINT 19 null
grade_outcomes.id graditemhist_out2_fk R

If this grade is related to an outcome, which one is it?

gradepass DECIMAL 10,5 0.00000

What grade is needed to pass? grademin < gradepass <= grademax

multfactor DECIMAL 10,5 1.00000

Multiply all grades by this

plusfactor DECIMAL 10,5 0.00000

Add this to all grades

aggregationcoef DECIMAL 10,5 0.00000

Aggregation coefficient used for category weights or other aggregation types

aggregationcoef2 DECIMAL 10,5 0.00000

Aggregation coefficient used for category weights or other aggregation types

sortorder BIGINT 19 0

Sorting order of the columns

hidden BIGINT 19 0

1 is hidden, > 1 is a date to hide until (prevents viewing)

locked BIGINT 19 0

1 is locked, > 1 is a date to lock until (prevents update)

locktime BIGINT 19 0

lock all final grades after this date

needsupdate BIGINT 19 0

If this flag is set, then the whole column will be recalculated

display BIGINT 19 0
decimals BIT 1 null
weightoverride BIT 1 0

Table contained -1 rows

grade_items_history table indexes

Constraint Name Type Sort Column(s)
PRIMARY Primary key Asc id
graditemhist_act_ix Performance Asc action
graditemhist_cat_ix Performance Asc categoryid
graditemhist_cou_ix Performance Asc courseid
graditemhist_log_ix Performance Asc loggeduser
graditemhist_old_ix Performance Asc oldid
graditemhist_out_ix Performance Asc outcomeid
graditemhist_sca_ix Performance Asc scaleid

grade_items_history table relationships