summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2024-01-28 14:11:41 +0300
committerGeorge Hazan <george.hazan@gmail.com>2024-01-28 14:11:41 +0300
commit10f748c2454c48f92e28ed987430cb5846df456a (patch)
tree10a320fed80879dbb6603735f04749c83653e3e3 /plugins
parent7602cfa123b322e836b482f0c830b145f029cb41 (diff)
fix for broken JSON functions in SQLITE 3.45
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Dbx_sqlite/src/dbevents.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/Dbx_sqlite/src/dbevents.cpp b/plugins/Dbx_sqlite/src/dbevents.cpp
index 81fc24fa39..55d4cd70aa 100644
--- a/plugins/Dbx_sqlite/src/dbevents.cpp
+++ b/plugins/Dbx_sqlite/src/dbevents.cpp
@@ -330,7 +330,7 @@ int CDbxSQLite::SetEventJson(MEVENT hDbEvent, const char *szSetting, DBVARIANT *
CMStringA tmp(FORMAT, "$.%s", szSetting);
{
mir_cslock lock(m_csDbAccess);
- sqlite3_stmt *stmt = InitQuery("UPDATE events SET data=json_set(data, ?, ?) WHERE id = ?;", qEvSetJson);
+ sqlite3_stmt *stmt = InitQuery("UPDATE events SET data=json_set(cast(data as text), ?, ?) WHERE id = ?;", qEvSetJson);
sqlite3_bind_text(stmt, 1, tmp, tmp.GetLength(), nullptr);
switch (dbv->type) {