diff options
-rw-r--r-- | OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs index cd72f58..c2ef9a5 100644 --- a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs +++ b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs | |||
@@ -184,9 +184,14 @@ namespace OpenSim.DataStore.MonoSqliteStorage | |||
184 | private SqliteCommand createUpdateCommand(string table, string pk, Dictionary<string, DbType> defs) | 184 | private SqliteCommand createUpdateCommand(string table, string pk, Dictionary<string, DbType> defs) |
185 | { | 185 | { |
186 | string sql = "update " + table + " set "; | 186 | string sql = "update " + table + " set "; |
187 | string subsql = ""; | ||
187 | foreach (string key in defs.Keys) { | 188 | foreach (string key in defs.Keys) { |
188 | sql += key + "= :" + key + ", "; | 189 | if (subsql.Length > 0) { // |
190 | subsql += ", "; | ||
191 | } | ||
192 | subsql += key + "= :" + key; | ||
189 | } | 193 | } |
194 | sql += subsql; | ||
190 | sql += " where " + pk; | 195 | sql += " where " + pk; |
191 | SqliteCommand cmd = new SqliteCommand(sql); | 196 | SqliteCommand cmd = new SqliteCommand(sql); |
192 | 197 | ||