Uploaded image for project: 'LAMS Development'
  1. LAMS Development
  2. LDEV-1435

Unable to create a new lesson due to the LAMSTWO table missing from the Moodle database

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.1.1
    • Fix Version/s: 2.2
    • Component/s: Moodle Integration
    • Labels:
      None

      Description

      When strict_trans_tables is turned on in MySQL, you can't have a default on a TEXT table.

      But the create script for the lamstwo tables has this, so when you install the module on a system with strict_trans_tables turned on, the table isn't created. You think it is all fine and you can create sequences, but you can't start lessons. The lesson starts on the LAMS side but it can't be recorded on the Moodle side.

      To fix - we need to remove the NOT NULL DEFAULT... from the instructions column. This means a change to the create script, and an update script to remove the default from any tables in existing systems. Make sure you test the create and update scripts with strict_trans_tables turned on and off.

        Activity

        Hide
        ernieg Ernie Ghiglione added a comment -
        I think this is a really easy fix. Can you fix this shortly Jun-Dir?
        Show
        ernieg Ernie Ghiglione added a comment - I think this is a really easy fix. Can you fix this shortly Jun-Dir?
        Hide
        jundirl Jun-Dir Liew added a comment -
        This is fixed when using the install.xml instead of the mysql.sql script (now deprecated).
        Show
        jundirl Jun-Dir Liew added a comment - This is fixed when using the install.xml instead of the mysql.sql script (now deprecated).

          People

          • Assignee:
            jundirl Jun-Dir Liew
            Reporter:
            fionam Fiona Malikoff
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development