]> err.no Git - dak/commitdiff
fix up SQL call (hackish)
authorMark Hymers <mhy@debian.org>
Sat, 14 Mar 2009 15:42:20 +0000 (15:42 +0000)
committerMark Hymers <mhy@debian.org>
Sat, 14 Mar 2009 15:42:20 +0000 (15:42 +0000)
Signed-off-by: Mark Hymers <mhy@debian.org>
daklib/dbconn.py

index c290b60f84a8f0c9f789c72c3843e7af58db516f..2b13123e50423f837a11ff61baba4811ffca6c72 100755 (executable)
@@ -548,11 +548,13 @@ class DBConn(Singleton):
         try:
             arch_id = self.get_architecture_id(package['Architecture'])
 
-                # Remove any already existing recorded files for this package
+            # Remove any already existing recorded files for this package
             c.execute("""DELETE FROM pending_content_associations
                          WHERE package=%(Package)s
                          AND version=%(Version)s
-                         AND arch_id=%d""" % arch_id, package )
+                         AND arch_id=%(ArchID)s""", {'Package': package['Package'],
+                                                     'Version': package['Version'],
+                                                     'ArchID':  arch_id})
 
             for fullpath in fullpaths:
                 (path, file) = os.path.split(fullpath)