mirror of
https://github.com/openhab/openhab-addons.git
synced 2025-02-04 19:34:05 +01:00
Provide better MySQL datatype for DateTimeType (#16604)
Resolves #15697 Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
This commit is contained in:
parent
79739c6930
commit
9a178cf1d5
@ -90,7 +90,7 @@ public class JdbcMysqlDAO extends JdbcBaseDAO {
|
|||||||
this.dbMeta = dbMeta;
|
this.dbMeta = dbMeta;
|
||||||
// Initialize sqlTypes, depending on DB version for example
|
// Initialize sqlTypes, depending on DB version for example
|
||||||
if (dbMeta.isDbVersionGreater(5, 5)) {
|
if (dbMeta.isDbVersionGreater(5, 5)) {
|
||||||
sqlTypes.put("DATETIMEITEM", "TIMESTAMP(3)");
|
sqlTypes.put("DATETIMEITEM", "DATETIME(3)");
|
||||||
sqlTypes.put("tablePrimaryKey", "TIMESTAMP(3)");
|
sqlTypes.put("tablePrimaryKey", "TIMESTAMP(3)");
|
||||||
sqlTypes.put("tablePrimaryValue", "NOW(3)");
|
sqlTypes.put("tablePrimaryValue", "NOW(3)");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user