Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
integration
prechecker
Commits
27cec472
Commit
27cec472
authored
Apr 13, 2016
by
David Monllaó
Browse files
Merge branch 'wip-MDL-53443-fix' of
git://github.com/marinaglancy/moodle
parents
10130303
47f4909a
Changes
1
Hide whitespace changes
Inline
Side-by-side
mod/feedback/analysis_course.php
View file @
27cec472
...
...
@@ -110,11 +110,7 @@ if (is_array($items)) {
}
if
(
$courseitemfilter
>
0
)
{
$avgvalue
=
'avg(value)'
;
if
(
$DB
->
get_dbfamily
()
==
'postgres'
)
{
// TODO: this should be moved to standard sql DML function ;-)
$avgvalue
=
'avg(cast (value as integer))'
;
}
$avgvalue
=
'avg('
.
$DB
->
sql_cast_char2int
(
'value'
,
true
)
.
')'
;
$sql
=
"SELECT fv.course_id, c.shortname,
$avgvalue
AS avgvalue
FROM
{
feedback_value
}
fv,
{
course
}
c,
{
feedback_item
}
fi
WHERE fv.course_id = c.id AND fi.id = fv.item AND fi.typ = ? AND fv.item = ?
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment