]> mj.ucw.cz Git - pciids.git/commitdiff
SQL syntax error
authorMichal Vaner <vorner@ucw.cz>
Mon, 1 Sep 2008 23:15:35 +0000 (01:15 +0200)
committerMichal Vaner <vorner@ucw.cz>
Mon, 1 Sep 2008 23:15:35 +0000 (01:15 +0200)
PciIds/DBQ.pm

index 99472a14e20e5f2b2ccf789be332a7fe8b840c5d..c2aef4b1b73d6cafefc2c076051270b2dc965740 100644 (file)
@@ -59,7 +59,7 @@ sub new( $ ) {
                'new-notif' => 'INSERT INTO notifications (user, location, recursive, type, notification) VALUES (?, ?, ?, ?, ?)',
                'notify' => 'INSERT INTO pending (user, history, notification, reason) SELECT DISTINCT user, ?, ?, ? FROM notifications WHERE ( notification = 2 OR notification = ? ) AND type <= ? AND ( location = ? OR ( recursive = 1 AND SUBSTR( ?, 1, LENGTH( location ) ) = location ) )',
                'newtime-mail' => 'UPDATE users SET nextmail = FROM_UNIXTIME( UNIX_TIMESTAMP( NOW() ) + 60 * mailgather ) WHERE nextmail < NOW() AND EXISTS ( SELECT 1 FROM notifications WHERE ( notification = 0 OR notification = 2 ) AND type <= ? AND ( location = ? OR ( recursive = 1 AND SUBSTR( ?, 1, LENGTH( location ) ) = location ) ) )',
-               'newtime-xmpp' => 'UPDATE users SET nextxmpp = FROM_UNIXTIME( UNIX_TIMESTAMP( NOW() ) + 60 * xmppgather ) WHERE nextxmpp < NOW() AND EXISTS ( SELECT 1 FROM notifications WHERE ( notification = 1 OR notification = 2 ) AND type <= ? AND ( location = ? OR ( recursive = 1 SUBSTR( ?, 1, LENGTH( location ) ) = location ) ) )',
+               'newtime-xmpp' => 'UPDATE users SET nextxmpp = FROM_UNIXTIME( UNIX_TIMESTAMP( NOW() ) + 60 * xmppgather ) WHERE nextxmpp < NOW() AND EXISTS ( SELECT 1 FROM notifications WHERE ( notification = 1 OR notification = 2 ) AND type <= ? AND ( location = ? OR ( recursive = 1 AND SUBSTR( ?, 1, LENGTH( location ) ) = location ) ) )',
                'mailout' => 'SELECT
                                pending.user, users.email,
                                pending.reason, history.discussion, history.nodename, history.nodenote, history.time,