aboutsummaryrefslogtreecommitdiffstats
path: root/src/libmsc/db.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libmsc/db.c')
-rw-r--r--src/libmsc/db.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libmsc/db.c b/src/libmsc/db.c
index f8f84f4b4..b12889f7a 100644
--- a/src/libmsc/db.c
+++ b/src/libmsc/db.c
@@ -541,10 +541,10 @@ rollback:
* database query results! */
#define SEL_COLUMNS \
"id," \
- "unixepoch(created)," \
+ "strftime('%s',created)," \
"sent," \
"deliver_attempts," \
- "unixepoch(valid_until)," \
+ "strftime('%s',valid_until)," \
"reply_path_req," \
"status_rep_req," \
"is_report," \
@@ -631,9 +631,9 @@ static const char *stmt_sql[] = {
[DB_STMT_SMS_DEL_EXPIRED] =
"DELETE FROM SMS WHERE id = $id",
[DB_STMT_SMS_GET_VALID_UNTIL_BY_ID] =
- "SELECT unixepoch(valid_until) FROM SMS WHERE id = $id",
+ "SELECT strftime('%s',valid_until) FROM SMS WHERE id = $id",
[DB_STMT_SMS_GET_OLDEST_EXPIRED] =
- "SELECT id, unixepoch(valid_until) FROM SMS ORDER BY valid_until LIMIT 1",
+ "SELECT id, strftime('%s',valid_until) FROM SMS ORDER BY valid_until LIMIT 1",
};
/***********************************************************************