Wrong type for field `time_micro` in table `sys_log`
As we log some custom events to `sys_log` we installed the log extension https://gitlab.com/co-stack.com/co-stack.com/typo3-extensions/logs mentioned at https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ApiOverview/Logging/Writers/Index.html.
The backend module sorts the log entries by the field `time_micro` of the table `sys_log`. However, the entries in this field getting stored not correctly because the type is defined as `float`
(https://github.com/TYPO3/TYPO3.CMS/blob/650d5d7ba771d2ad854f2475b7b7d4aff70c9d2c/typo3/sysext/core/ext_tables.sql#L384). While the real microtime in PHP was something like `1617029996.5212` I got `1617030000` in all records:
Changing the type to `decimal(14,4)` fixed the issue.
Updated by Andreas Kienast over 1 year ago
- Status changed from New to Needs Feedback
can you please tell which database you're using and if this is still an issue? We were not able to reproduce the issue in v11 and v12 with MySQL 5.7 and MariaDB 10.2 with passing