Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-29390 DB layer improvements 2.2 META
  3. MDL-29322

oracle driver creates varchar size in bytes instead of utf-8 chars

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0, 2.1, 2.2
    • Fix Version/s: 2.2
    • Component/s: Database SQL/XMLDB
    • Labels:
    • Testing Instructions:
      Hide

      0) This requires access as DBA to grant some perms and install PL/SQL packages.

      1) Install Moodle 2.2. under Oracle => no error should happen

      2) Upgrade Moodle 2.1 to 2.2 under Oracle => no error should happen

      3) Run the DB functional tests: Some failures related to column lengths may happen.

      Notes for 3):

      • More exactly the errors happen in one test_add_field() and one test_temp_tables() test, both asserting values related with max_length.
      • Only those and the concat failure should happen (don't forget to install the moodle PL/SQL package or more failures will be shown).
      • Finally, note that if MDL-29415 has been integrated too, then no failures related to column lengths will happen anymore.
      Show
      0) This requires access as DBA to grant some perms and install PL/SQL packages. 1) Install Moodle 2.2. under Oracle => no error should happen 2) Upgrade Moodle 2.1 to 2.2 under Oracle => no error should happen 3) Run the DB functional tests: Some failures related to column lengths may happen. Notes for 3): More exactly the errors happen in one test_add_field() and one test_temp_tables() test, both asserting values related with max_length. Only those and the concat failure should happen (don't forget to install the moodle PL/SQL package or more failures will be shown). Finally, note that if MDL-29415 has been integrated too, then no failures related to column lengths will happen anymore.
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_22_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      w37_MDL-29322_m22_oraclebytes

      Description

      VARCHAR2(255) should be in fact VARCHAR2(255 CHAR) in order to prevent problems on servers with default configuration.

      Sources of information:
      http://ss64.com/ora/syntax-datatypes.html
      http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/sql_elements001.htm
      http://download.oracle.com/docs/cd/B19306_01/server.102/b14225/ch3globenv.htm#i1008522

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    5/Dec/11