SUMMARY
This Knowledge Base article describes an issue that has been classified as a defect by Strategy. When logging report job SQL statistics for a report job whose SQL contains single quotes, the "Insert into STG_IS_REP_SQL_STATS" statement fails and an ODBC syntax error is seen in the DSSErrors.log. This issue has been addressed in Strategy Secure Enterprise 10.10 and 10.4 Hotfix 6.
SYMPTOM
In Strategy Intelligence Server 10.x, when report job SQL statistics are enabled and a report is run against the warehouse, statistics are logged to the STG_IS_REP_SQL_STATS table. If the report SQL contains single quotes, an ODBC syntax error message appears in the DSSErrors.log on the Intelligence Server machine.
Below is an example of this error message for a MySQL statistics repository. The error message may vary depending on the database type.
Error type: Odbc error. Odbc operation attempted: SQLExecDirect. [42000:1064: on SQLHANDLE] [MySQL][ODBC 5.3(w) Driver][mysqld-5.6.19-enterprise-commercial-advanced-log]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 "[REPORT SQL]..... a' at line 1 Connection String: DSN=MSTR_EM_STATS;UID=MSTR_user;. SQL Statement: insert into STG_IS_REP_SQL_STATS...