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

Add 'EXPLAIN' to slow quries

XMLWordPrintable

    • Any
    • MOODLE_404_STABLE
    • master-MDL-79926
    • Hide
      1. In moodle config add in $CFG->dboptions array 'logall' => true
      2. Open few pages in moodle site
      3. verify new entry are loged in {log_queries} table
      4. check that in info filed there is php array with data explain how db engin run the quey and the error field is 0
      5. replace   $CFG->dboptions  'logall' => true to 'logslow' => 0.001 and repeat steps 1-4
      6. Change to differnet type of DB and return all the steps above
      Show
      In moodle config add in $CFG->dboptions array 'logall' => true Open few pages in moodle site verify new entry are loged in {log_queries} table check that in info filed there is php array with data explain how db engin run the quey and the error field is 0 replace   $CFG->dboptions  'logall' => true to 'logslow' => 0.001 and repeat steps 1-4 Change to differnet type of DB and return all the steps above
    • 2

      When 'logslow' are enable in $CFG->dboptions array and the qurey run time is more then the 'logslow' value add explain to info field.

            avimoto Avi Levy
            avimoto Avi Levy
            Meirza Meirza
            Votes:
            6 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 6 hours
                6h

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.