src/strip.vala
[app.mailtrimmer] / src / strip.vala
index 06b068a..4223b03 100644 (file)
@@ -370,7 +370,7 @@ public class Strip : GLib.Object {
        
        // initialize it with known data..
        // that should wipe out dupes.
-       var matches = this.execute("SELECT count(id) as nid FROM Attachment WHERE id = %d".printf(
+       var matches = this.execute("SELECT id   FROM Attachment WHERE id = %d".printf(
                        int.parse(sid)));  
 
                 
@@ -455,7 +455,7 @@ public class Strip : GLib.Object {
                
 
       
-               this.query("""
+               this.execute("""
                       
                       
                                INSERT INTO Attachment  (  
@@ -497,8 +497,8 @@ public class Strip : GLib.Object {
                                    %d, -- size
                                    
                                    '%s', -- checkum
-                                       '%s' --created:
-                               )"
+                                       '%s' -- created:
+                               )
                       
                       
                      """.printf(
@@ -691,7 +691,13 @@ public class Strip : GLib.Object {
     {
            return this.real_query(false, str);
     }
-    public string real_query(bool need_return, string str)
+    /**
+    * need_return 
+    0 = no
+    1 = yes
+    -1 = don't try.
+    */
+    public string real_query(int need_return, string str)
     {
                GLib.debug("Before Query : %u  : %s\n", this.mysql.errno(), this.mysql.error());