Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

Update Problem Testrail

Hi Guys,

today I wanted to update Testrail to version Unfortunately, it failed. As usual, I changed the folders under / var / www / testrail. Then i use the terminal and go to the testrail installation and have run “php run.php update”. There came the first mistake:

“You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(6) null”

So i started the Apache Server.

Now i went to our internal Testrail Page to veryfie the Install Files . There is no Problem, until i click to update the DB

Now this error appears:
[DatabaseException] Table ‘report_api_templates’ already exists

So i logged into php-myadmin page and try to delete the Table "report_api_templates.
But when i do the update again, the same error appears.
The same error i get before by the last update too. And i let it be.
But now i want to know why this happens.
Have anybody a idea?

Ubuntu Version is 14.04
PHP is 7.2.

I am no SQL or PHP Pro, so i need a easy manuel for this issue please.


I don’t have the exact answer for you, but our team did encounter the same type of error on the update. Below is the update from my system support team as they attempted to Updated our Pre-Production test server with the latest version of TestRail (v6.0), and the DataBase from our Production level TestRail server (v5.6):

Table ‘report_api_templates’ already exists (updating version 190)

My Support Team logged the following on the tool upgrade:

Issue: Update pre-production test server to TestRail version

Notes from System Support:

Because of the different versions of the TestRail database on the pre-production test server & the production test server, we did the following to get pre-production test server updated for you. Each attempt to update pre-production test server we got this error: Table ‘report_api_templates’ already exists (updating version 190)

To fix:

Verified that report_api_templates table did not exist in TestRail DB on production level server.
Unzip TestRail files on pre-production test server to match Production TestRail server (

Dropped Production TestRail DB on pre-production test server and recreated it, then I was able to put testrail’s db on pre-production test server, then upgrade the testrail app on pre-production test server to

To drop db on pre-production test server:

  • drop database testrail;
  • CREATE DATABASE testrail DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
  • GRANT ALL ON testrail.* TO ‘testrail’@‘localhost’;

pre-production test server is now ready for your team.

Outside of this, I can’t really help anymore, but maybe if you haven’t solved your issue yet, this will give you an idea where to look.

PS, I believe we run our production server on a Linux CentOS system.