Problem Description
The WebUI fails to load timestamp ranges properly when using MySQL as the underlying storage engine due to invalid SQL syntax in CAST operations.
Root Cause
The keyword "INTEGER" is not a valid target for CAST operations in MySQL, causing SQL syntax errors.
Impact
- Timestamp range functionality broken in WebUI when using MySQL storage engine
- Error logs show: "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 'INTEGER'"
Solution
Replace "INTEGER" with "UNSIGNED" in CAST operations to ensure MySQL compatibility while maintaining MariaDB compatibility.
Steps to Reproduce
- Configure MySQL as the underlying storage engine
- Compress logs with valid timestamps
- Check WebUI - timestamp range fails to load properly
- Check container logs for SQL syntax errors
Related
Validation
Problem Description
The WebUI fails to load timestamp ranges properly when using MySQL as the underlying storage engine due to invalid SQL syntax in CAST operations.
Root Cause
The keyword "INTEGER" is not a valid target for CAST operations in MySQL, causing SQL syntax errors.
Impact
Solution
Replace "INTEGER" with "UNSIGNED" in CAST operations to ensure MySQL compatibility while maintaining MariaDB compatibility.
Steps to Reproduce
Related
BIGINTvalues asUNSIGNEDto fix MySQL-specific type errors in dashboard stats queries (fixes #1137). #1136Validation