mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-04-03 20:38:50 +00:00
* Tools/SOGoToolExpireUserSessions.m:
semi-colon are useless in sql queries and probably breaks on oracle Monotone-Parent: e699f14b51f9de020728f6ca36fdcc283587d057 Monotone-Revision: aadc4759a64f724760d38bbdfd92715182856439 Monotone-Author: jraby@inverse.ca Monotone-Date: 2012-06-21T15:51:53
This commit is contained in:
@@ -109,7 +109,7 @@
|
||||
return rc=NO;
|
||||
}
|
||||
|
||||
sql = [NSString stringWithFormat: @"SELECT count(*) FROM %@ WHERE c_lastseen <= %d;",
|
||||
sql = [NSString stringWithFormat: @"SELECT count(*) FROM %@ WHERE c_lastseen <= %d",
|
||||
[tableURL gcsTableName], oldest];
|
||||
ex = [channel evaluateExpressionX: sql];
|
||||
if (ex)
|
||||
@@ -129,7 +129,7 @@
|
||||
if (verbose)
|
||||
NSLog(@"Will be removing %d sessions", sessionsToDelete);
|
||||
[channel cancelFetch];
|
||||
sql = [NSString stringWithFormat: @"DELETE FROM %@ WHERE c_lastseen <= %d;",
|
||||
sql = [NSString stringWithFormat: @"DELETE FROM %@ WHERE c_lastseen <= %d",
|
||||
[tableURL gcsTableName], oldest];
|
||||
if (verbose)
|
||||
NSLog(@"Removing sessions older than %d minute(s)", nbMinutes);
|
||||
|
||||
Reference in New Issue
Block a user