Trying to apply the database schema from etc/upgrade/4.1.7/schema.mysql
and MariaDB 10.5 is throwing this error
ERROR 1292 (22007): Truncated incorrect DOUBLE value: ''
I had to turn off STRICT_TRANS_TABLES
to get the sql to work.
SET SESSION SQL_MODE = "ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION";
Is this a bug?
Problem with my data?
Here is what my etc/upgrade/4.1.7/schema.mysql
looks like
SET SESSION SQL_MODE = "ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION";
UPDATE Transactions
SET TimeTaken
= COALESCE(NewValue,0)
- COALESCE(OldValue,0)
WHERE ObjectType = 'RT::Ticket' AND Type = 'Set' AND Field = 'TimeWorked';
SET SESSION SQL_MODE = "STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION";