Network Management
Report Writer failed to run report with SQL Error : "Operand type clash: datetime2 is incompatible with int"
When running a report created with Report Writer the report will fail with the SQL Error: Operand type clash: datetime2 is incompatible with int
First published date
Last published date
Overview
ERROR:
SQL Error:
"Operand type clash: datetime2 is incompatible with int"
Product section
Cause
Resolution
You would need to recreate the report using the web-based report writer.
Manage and view reports in the Orion Platform
Resolution 2
Migrate failing custom SQL reports with the datetime2 error
Starting with Orion Platform 2020.2.5, you can follow these steps to migrate legacy reports with the datetime2 error.
- Log in to the server hosting your main polling engine.
- Open the LegacyReportMigration.exe.config file and set the CustomSQLEvaluation option to "true".
- If the report uses non-default date column, extend then DateTimeColumns setting.
- If the date column is wrapped by "[" and "]" within the SQL query, add "\" before the square bracket "[" or "]".
- Start the Legacy Migration Tool and migrate the report.