From aab0cd18515ac0d0ec961b59c65cadcea55ec78a Mon Sep 17 00:00:00 2001 From: stronk7 Date: Sun, 15 Feb 2009 23:23:41 +0000 Subject: [PATCH] MDL-18244 sql_length() - apply new function to resource names filter ; merged from 19_STABLE --- mod/resource/filter.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mod/resource/filter.php b/mod/resource/filter.php index 54826a741e..6ecfcc7594 100644 --- a/mod/resource/filter.php +++ b/mod/resource/filter.php @@ -43,7 +43,7 @@ cm.visible = 1 AND r.id = cm.instance AND cm.course = ? - ORDER BY CHAR_LENGTH(r.name) DESC, cm.section ASC"; + ORDER BY " . $DB->sql_length('r.name') . " DESC, cm.section ASC"; if (!$resources = $DB->get_records_sql($resource_sql, array($courseid)) ){ $nothingtodo = true; -- 2.39.5