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

Get consistent results with out-of-range limit clauses under all databases

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • 2.0.3
    • MSSQL , SQLSRV driver v1.1, (and since the code really isn't in moodle core yet as of writing) a do_query which is not using emulated limits but scrollable (using SQLSRV_CURSOR_STATIC)
    • Microsoft SQL
    • MOODLE_20_STABLE
    • Moderate

      while working on MDL-26458, i created some unit tests that are good but failing:

      $DB->get_records_sql($sql, null, 21098765432109876543210, 2) fails

      • Equal expectation fails because [Integer: 0] differs from [Integer: 2] by 2 at [/home/aparup/mcode/m20/mysql/moodle/lib/dml/simpletest/testdml.php line 1100]

      $DB->get_records_sql($sql, null, 21098765432109876543210, 21098765432109876543210) fails

      • Equal expectation fails because [Integer: 0] differs from [Integer: 4] by 4 at [/home/aparup/mcode/m20/pg/moodle/lib/dml/simpletest/testdml.php line 1104]

      these were testing the limitfrom and limitnum using the scrollable cursored resultsets with SQLSRV driver (see MDL-26458)

            moodle.com Moodle HQ
            nebgor Aparup Banerjee
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

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