Opened 8 years ago
Last modified 8 years ago
#26868 closed Bug
Change MySQL version detection to accomodate MariaDB — at Version 1
Reported by: | Marc-Aurèle Brothier | Owned by: | nobody |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | 1.9 |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Accepted | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description (last modified by )
I found an edge case when you connect to mariadb server using the mysql client library, for example running a MySQL server on a local computer, which will install the client library but using a MariaDB in a docker container.
The server string returned by the server is 5.5.5-10.0.25-MariaDB-1~jessie
and therefore the features list is incorrect, especially for the microsecond precision on the DATETIME. If you're using the mariadb client library you will get 10.0.25-MariaDB-1~jessie
and the features list is correct.
https://mariadb.atlassian.net/browse/MDEV-4575
My PR changes how the version is detected, and use a SQL query instead of the client library call. Then we get the correct MariaDB version and the features list is correct.
Change History (1)
comment:1 by , 8 years ago
Description: | modified (diff) |
---|---|
Has patch: | set |
Summary: | Microsecond precision in MariaDB / Version detection → Change MySQL version detection to accomodate MariaDB |
Triage Stage: | Unreviewed → Accepted |
I'm not a MariaDB/MySQL expert, but tentatively accepting.