MDL-80286 datafield_date: cast field content to real when sorting.
This ensures we don't under/overflow the size of an integer in DB.
This commit is contained in:
@@ -198,7 +198,7 @@ class data_field_date extends data_field_base {
|
||||
|
||||
function get_sort_sql($fieldname) {
|
||||
global $DB;
|
||||
return $DB->sql_cast_char2int($fieldname, true);
|
||||
return $DB->sql_cast_char2real($fieldname, true);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user