MDL-61993 profilefield_checkbox: take rid of oracle reserved word
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Fri, 27 Apr 2018 08:41:46 +0000 (10:41 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Fri, 27 Apr 2018 08:41:46 +0000 (10:41 +0200)
user/profile/field/checkbox/classes/privacy/provider.php

index 71c5ec9..3e1cea1 100644 (file)
@@ -65,13 +65,13 @@ class provider implements
      */
     public static function get_contexts_for_userid(int $userid) : contextlist {
         $sql = "SELECT ctx.id
-                FROM {user_info_data} uid
+                FROM {user_info_data} uda
                 JOIN {user_info_field} uif
-                    ON uid.fieldid = uif.id
+                    ON uda.fieldid = uif.id
                 JOIN {context} ctx
-                    ON ctx.instanceid = uid.userid
+                    ON ctx.instanceid = uda.userid
                         AND ctx.contextlevel = :contextlevel
-                WHERE uid.userid = :userid
+                WHERE uda.userid = :userid
                     AND uif.datatype = :datatype";
         $params = [
             'userid' => $userid,
@@ -151,10 +151,10 @@ class provider implements
         global $DB;
 
         $sql = "SELECT *
-                FROM {user_info_data} uid
+                FROM {user_info_data} uda
                 JOIN {user_info_field} uif
-                    ON uid.fieldid = uif.id
-                WHERE uid.userid = :userid
+                    ON uda.fieldid = uif.id
+                WHERE uda.userid = :userid
                     AND uif.datatype = :datatype";
         $params = [
             'userid' => $userid,