[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdelibs/plasma/private
From:       Marco Martin <notmart () gmail ! com>
Date:       2010-10-24 17:04:44
Message-ID: 20101024170444.3F288AC897 () svn ! kde ! org
[Download RAW message or body]

SVN commit 1189333 by mart:

fix both retrieve queries


 M  +2 -2      storage.cpp  


--- trunk/KDE/kdelibs/plasma/private/storage.cpp #1189332:1189333
@@ -96,11 +96,11 @@
         query.exec();
 
         //a bit redundant but should be the faster way with less string concatenation as possible
-        if (params["key"].isNull()) {
+        if (params["key"].toString().isEmpty()) {
             query.prepare("select * from "+m_clientName+" where valueGroup=:valueGroup");
             query.bindValue(":valueGroup", valueGroup);
         } else {
-            query.prepare("select * from "+m_clientName+" where valueGroup=:valueGroup and key=:key");
+            query.prepare("select * from "+m_clientName+" where valueGroup=:valueGroup and id=:key");
             query.bindValue(":valueGroup", valueGroup);
             query.bindValue(":key", params["key"].toString());
         }
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic