Bugzilla Importer Fails with MySQLSyntaxErrorException
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Symptoms
When importing using the Bugzilla importer, the following error occurs:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
http-8080-Processor47 ERROR [web.action.util.DatabaseConnectionBean] Error occurred while connecting to the database.
com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: You have an error in your SQL syntax near 'SESSION VARIABLES' at line 1
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:936)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723)
at com.mysql.jdbc.Connection.execSQL(Connection.java:3277)
at com.mysql.jdbc.Connection.execSQL(Connection.java:3206)
at com.mysql.jdbc.Statement.executeQuery(Statement.java:1232)
at com.mysql.jdbc.Connection.loadServerVariables(Connection.java:4478)
at com.mysql.jdbc.Connection.initializePropsFromServer(Connection.java:4062)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2789)
at com.mysql.jdbc.Connection.<init>(Connection.java:1555)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:285)
Cause
The error can occur if you're using using the MySQL Connector 5.X JDBC driver with MySQL Server 3.X.
Resolution
Download the latest MySQL JDBC driver for your MySQL version and re-run the Bugzilla import.
Was this helpful?