Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-34069

Bulk Delete of Users Fails on MS SQL Server

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 2.3
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      2008R2 Server IIS7.5 MSSQL 10 (2008)
    • Database:
      Microsoft SQL
    • Testing Instructions:
      Hide

      See description

      Show
      See description
    • Workaround:
      Hide

      Delete one at a time!

      Show
      Delete one at a time!
    • Affected Branches:
      MOODLE_23_STABLE

      Description

      MS SQL 2008 v10/IIS7.5/Windows Server 2008R2

      Site Admin -> Users -> Accounts -> Bulk User Administration

      Select one user to delete - OK
      Select two or more users to delete - error below

      I did report a similar error with 2.2 ages ago - has it reoccurred again? Sorry I don't know the number.

      Developer Debug below

      Debug info: SQLState: 42000<br>
      Error Code: 3988<br>
      Message: [Microsoft][SQL Server Native Client 11.0][SQL Server]New transaction is not allowed because there are other threads running in the session.<br>

      native sqlsrv_begin_transaction
      [NULL]
      Error code: dmlreadexception
      Stack trace:
      line 407 of \lib\dml\moodle_database.php: dml_read_exception thrown
      line 258 of \lib\dml\sqlsrv_native_moodle_database.php: call to moodle_database->query_end()
      line 1368 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->query_end()
      line 2101 of \lib\dml\moodle_database.php: call to sqlsrv_native_moodle_database->begin_transaction()
      line 928 of \lib\completionlib.php: call to moodle_database->start_delegated_transaction()
      line 524 of \lib\completionlib.php: call to completion_info->internal_set_data()
      line 1157 of \lib\completionlib.php: call to completion_info->update_state()
      line 836 of \lib\grade\grade_grade.php: call to completion_info->inform_grade_changed()
      line 284 of \lib\grade\grade_object.php: call to grade_grade->notify_changed()
      line 1306 of \lib\gradelib.php: call to grade_object->delete()
      line 3898 of \lib\moodlelib.php: call to grade_user_delete()
      line 30 of \admin\user\user_bulk_delete.php: call to delete_user()

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              dobedobedoh Andrew Nicols
              Reporter:
              jgcracknell James Cracknell
              Participants:
              Component watchers:
              Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón
              Votes:
              7 Vote for this issue
              Watchers:
              11 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: