From 44a3a3384c32cf8414ee860932774592a91d0019 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Tue, 21 Jan 2014 00:51:31 +0100 Subject: mod_storage_sql2: Fix another SQL syntax error that slipped trough --- plugins/mod_storage_sql2.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins/mod_storage_sql2.lua') diff --git a/plugins/mod_storage_sql2.lua b/plugins/mod_storage_sql2.lua index b9e9d3ca..e02ad681 100644 --- a/plugins/mod_storage_sql2.lua +++ b/plugins/mod_storage_sql2.lua @@ -224,7 +224,7 @@ function archive_store:append(username, key, when, with, value) return engine:transaction(function() local key = key or uuid.generate(); local t, value = serialize(value); - engine:delete("DELETE FROM `prosodyarchive` WHERE `host`=? AND `user`=? AND `store`=? AND KEY=?", host, user or "", store, key); + engine:delete("DELETE FROM `prosodyarchive` WHERE `host`=? AND `user`=? AND `store`=? AND `key`=?", host, user or "", store, key); engine:insert("INSERT INTO `prosodyarchive` (`host`, `user`, `store`, `when`, `with`, `key`, `type`, `value`) VALUES (?,?,?,?,?,?,?,?)", host, user or "", store, when, with, key, t, value); return key; end); -- cgit v1.2.3