From 42de762b431af30939330c7aaa955361f6038914 Mon Sep 17 00:00:00 2001 From: Christoph Weitkamp Date: Wed, 16 Dec 2020 07:36:35 +0100 Subject: [PATCH] [jdbc] Reduce size for VARCHAR columns (#9394) Signed-off-by: Christoph Weitkamp --- .../java/org/openhab/persistence/jdbc/db/JdbcMariadbDAO.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bundles/org.openhab.persistence.jdbc/src/main/java/org/openhab/persistence/jdbc/db/JdbcMariadbDAO.java b/bundles/org.openhab.persistence.jdbc/src/main/java/org/openhab/persistence/jdbc/db/JdbcMariadbDAO.java index 2e243eb60..f7d4a9c35 100644 --- a/bundles/org.openhab.persistence.jdbc/src/main/java/org/openhab/persistence/jdbc/db/JdbcMariadbDAO.java +++ b/bundles/org.openhab.persistence.jdbc/src/main/java/org/openhab/persistence/jdbc/db/JdbcMariadbDAO.java @@ -46,6 +46,8 @@ public class JdbcMariadbDAO extends JdbcBaseDAO { */ private void initSqlTypes() { logger.debug("JDBC::initSqlTypes: Initialize the type array"); + sqlTypes.put("IMAGEITEM", "VARCHAR(16255)"); + sqlTypes.put("STRINGITEM", "VARCHAR(16255)"); // MariaDB using utf-8 max = 16383, using 16383-128 = 16255 } /**