comparison src/memory/sqlite.py @ 441:a6640bb8ee95

core: fixed bad query in Sqlite storage
author Goffi <goffi@goffi.org>
date Sat, 03 Dec 2011 22:21:27 +0100
parents 5e9d28ca5109
children 17c7e48bf68f
comparison
equal deleted inserted replaced
440:48277946348b 441:a6640bb8ee95
229 def fillPrivates(result): 229 def fillPrivates(result):
230 for private in result: 230 for private in result:
231 key,value = private 231 key,value = private
232 private_gen[key] = value 232 private_gen[key] = value
233 debug(_("loading general private values [namespace: %s] from database") % (namespace,)) 233 debug(_("loading general private values [namespace: %s] from database") % (namespace,))
234 d = self.dbpool.runQuery("SELECT key,value FROM private_gen WHERE namespace=?", namespace).addCallback(fillPrivates) 234 d = self.dbpool.runQuery("SELECT key,value FROM private_gen WHERE namespace=?", (namespace,)).addCallback(fillPrivates)
235 return d.addErrback(lambda x: debug(_("No data present in database for namespace %s") % namespace)) 235 return d.addErrback(lambda x: debug(_("No data present in database for namespace %s") % namespace))
236 236
237 def loadIndPrivates(self, private_ind, namespace, profile): 237 def loadIndPrivates(self, private_ind, namespace, profile):
238 """Load individual private values 238 """Load individual private values
239 @param privates_ind: dictionary to fill 239 @param privates_ind: dictionary to fill