The answer you entered to the math problem is incorrect.

Known limitations of SELECT ... WHERE ... IN ()? (2 replies)

Below I have some PHP code which is a loop to go through and delete a series of users; however, it seems to fail when $in is too large. I'm trying to figure out what determines too large? Is it a PHP issue of the variable being too long? Is it a MySQL issue of how big $in can be? If I can figure it out what/where the limitation is then I could probably program around it by dumping $in into an array and processing it in chunks. Any suggestions or ideas would be appreciated?

Peace - Anthony Borrow, SJ

--- code segment ---

$in = implode(',', $SESSION->bulk_users);

if ($rs = get_recordset_select('user', "id IN ($in)")) {

while ($user = rs_fetch_next_record($rs)) {

if ($primaryadmin->id != $user->id and $USER->id != $user->id and delete_user($user)) {

unset($SESSION->bulk_users[$user->id]);

} else {

notify(get_string('deletednot', '', fullname($user, true)));

}

}

Reply

Please solve the math problem above and type in the result. e.g. for 1+1, type 2.