Troubleshooting: Running a performance test with a MySQL database

You can troubleshoot an issue that you encounter while you run a performance test with a MySQL database.

About this task

If you are using MySQL version 5.7 or later, the SQL mode ONLY_FULL_GROUP_BY is enabled by default. This mode must be removed, otherwise, when you run a performance test from Rational® Integration Tester with a MySQL database, an error is reported for the GROUP BY clause.

To remove this mode, follow these steps:

Procedure

  • For Windows or Linux follow these steps:
    1. Edit the MySQL configuration file my.ini on Windows or my.cnf on Linux. Set the sql_mode parameter from a command line in one of two ways:
      sql_mode="STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION"
        
      sql_mode=""
    2. Restart the MySQL server.
  • For Ubuntu follow these steps:
    1. Create the following file:
      /etc/mysql/conf.d/disable_strict_mode.cnf
    2. Edit the file. Copy and paste the following command into the disable_strict_mode.cnf file to set the sql_mode parameter:
      [mysqld]
      sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
    3. Restart the MySQL server.
      sudo service mysql restart
    4. Check that the mode was removed:
      <mysql> select @@sql_mode
      The result shows you the following:
      STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION