Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-14679 META: DB layer 2.0
  3. MDL-17347

Need to put back the debug code that tells you if your first column is not unique in get_records_sql

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Fixed
    • Icon: Major Major
    • 2.0
    • 2.0
    • Database SQL/XMLDB
    • None
    • MOODLE_20_STABLE
    • MOODLE_20_STABLE

      I have just messed up by writing a complicated query where it turned out that the first column was not unique (again!).

      I notice that pgsql_native_moodle_database.php does not have the nice debugging code I wrote that tells you immediately if you make this mistake. Please can you add it (around like 650 - maybe other methods need it to).

      And in adodb_moodle_database.php (around like 470) the code is no longer effective, since we are doing $records = $rs->GetAssoc(true) - which, in isolation, seems like a good idea - but makes it impossible to detect this common programming error.

            skodak Petr Skoda
            timhunt Tim Hunt
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

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