summaryrefslogtreecommitdiffstats
path: root/db.vala
diff options
context:
space:
mode:
Diffstat (limited to 'db.vala')
-rw-r--r--db.vala10
1 files changed, 5 insertions, 5 deletions
diff --git a/db.vala b/db.vala
index 3135ae7..5bb3504 100644
--- a/db.vala
+++ b/db.vala
@@ -90,7 +90,7 @@ public class Database {
int64 timestamp = (new DateTime.now_utc()).to_unix();
this.purchase_stmt1.reset();
- this.purchase_stmt1.bind_text(1, "%lld".printf(user));
+ this.purchase_stmt1.bind_text(1, "%d".printf(user));
this.purchase_stmt1.bind_text(2, "%llu".printf(article));
this.purchase_stmt1.bind_text(3, "%llu".printf(timestamp));
@@ -133,7 +133,7 @@ public class Database {
int rc = 0;
this.undo_stmt1.reset();
- this.undo_stmt1.bind_text(1, "%llu".printf(user));
+ this.undo_stmt1.bind_text(1, "%d".printf(user));
rc = this.undo_stmt1.step();
switch(rc) {
@@ -141,14 +141,14 @@ public class Database {
pid = uint64.parse(this.undo_stmt1.column_text(0));
break;
case Sqlite.DONE:
- stdout.printf("undo not possible without purchases");
+ stdout.printf("undo not possible without purchases\n");
return false;
default:
error("[interner Fehler: %d]".printf(rc));
}
this.undo_stmt2.reset();
- this.undo_stmt2.bind_text(1, "%llu".printf(user));
+ this.undo_stmt2.bind_text(1, "%d".printf(user));
rc = this.undo_stmt2.step();
if(rc != Sqlite.DONE)
@@ -181,7 +181,7 @@ public class Database {
int64 timestamp = (new DateTime.now_utc()).to_unix();
this.stock_stmt1.reset();
- this.stock_stmt1.bind_text(1, "%llu".printf(user));
+ this.stock_stmt1.bind_text(1, "%d".printf(user));
this.stock_stmt1.bind_text(2, "%llu".printf(product));
this.stock_stmt1.bind_text(3, "%llu".printf(amount));
this.stock_stmt1.bind_text(4, "%llu".printf(timestamp));