# HG changeset patch # User Kim Alvefur # Date 1390261891 -3600 # Node ID aa7534a877fe2618b25c5d856837ddf853e65e8a # Parent ef11b8bab40581a8c19f245bcb41020816c90e67 mod_storage_sql2: Fix another SQL syntax error that slipped trough diff -r ef11b8bab405 -r aa7534a877fe plugins/mod_storage_sql2.lua --- a/plugins/mod_storage_sql2.lua Sat Jan 18 18:46:12 2014 +0000 +++ b/plugins/mod_storage_sql2.lua Tue Jan 21 00:51:31 2014 +0100 @@ -224,7 +224,7 @@ 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);