mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 05:58:34 +01:00
MDL-61028 core_search: Fix SELECT bug affecting Oracle
This commit is contained in:
parent
ac8f106b4d
commit
acaeb5ec41
@ -261,7 +261,7 @@ class core_user {
|
|||||||
if (!in_array('deleted', $extra)) {
|
if (!in_array('deleted', $extra)) {
|
||||||
$extrafieldlist[] = 'deleted';
|
$extrafieldlist[] = 'deleted';
|
||||||
}
|
}
|
||||||
$extrafields = \user_picture::fields('u',
|
$selectfields = \user_picture::fields('u',
|
||||||
array_merge(get_all_user_name_fields(), $extrafieldlist));
|
array_merge(get_all_user_name_fields(), $extrafieldlist));
|
||||||
|
|
||||||
$index = 1;
|
$index = 1;
|
||||||
@ -327,7 +327,7 @@ class core_user {
|
|||||||
$readcount = $max + 2;
|
$readcount = $max + 2;
|
||||||
for ($i = 0; $i < $querylimit; $i++) {
|
for ($i = 0; $i < $querylimit; $i++) {
|
||||||
$rawresult = $DB->get_records_sql("
|
$rawresult = $DB->get_records_sql("
|
||||||
SELECT users.*, $extrafields
|
SELECT $selectfields
|
||||||
FROM ($userquery) users
|
FROM ($userquery) users
|
||||||
JOIN {user} u ON u.id = users.id
|
JOIN {user} u ON u.id = users.id
|
||||||
WHERE $where
|
WHERE $where
|
||||||
|
Loading…
x
Reference in New Issue
Block a user