Displaying 3 results from an estimated 3 matches for "mergeexpire".
Did you mean:
mergeexpires
2009 Aug 09
1
Wiki entry for expire plugin, PostgreSQL trigger needs update
...xists(SELECT 1 FROM expires WHERE username = NEW.username AND mailbox = NEW.mailbox) THEN
UPDATE expires SET expire_stamp = NEW.expire_stamp
WHERE username = NEW.username AND mailbox = NEW.mailbox;
RETURN NULL;
ELSE
RETURN NEW;
END IF;
END;
$$ LANGUAGE plpgsql;
CREATE TRIGGER mergeexpires BEFORE INSERT ON expires
FOR EACH ROW EXECUTE PROCEDURE merge_expires();
At least that's what I think after looking at the code:
iter = dict_iterate_init(dict, DICT_EXPIRE_PREFIX,
DICT_ITERATE_FLAG_RECURSE |
DICT_ITERATE_FLAG_SORT_BY_VALUE);
/* We'll g...
2010 Aug 24
5
When should dictionary entries for the expire plugin be added/updated?
...mailbox
}
}
# Schema dump of /var/lib/dovecot/expires.sqlite
PRAGMA foreign_keys=OFF;
BEGIN TRANSACTION;
CREATE TABLE expires (
username VARCHAR(75) NOT NULL,
mailbox VARCHAR(255) NOT NULL,
expire integer NOT NULL,
PRIMARY KEY (username, mailbox)
);
CREATE TRIGGER mergeexpire BEFORE INSERT ON expires FOR EACH ROW
BEGIN
UPDATE expires SET expire=NEW.expire
WHERE username=NEW.username AND mailbox=NEW.mailbox;
SELECT RAISE(IGNORE)
WHERE (SELECT 1 FROM expires WHERE username=NEW.username AND mailbox=NEW.mailbox) IS NOT NULL;
END;
COMMIT;
With thes...
2010 Apr 08
2
Dovecot 2.0 beta4 and Expire Plugin
...es
value_field = expire_stamp
fields {
username = $user
mailbox = $mailbox
}
}
sqlite shows schema:
CREATE TABLE expires (
username varchar(100) not null,
mailbox varchar(255) not null,
expire_stamp integer not null,
primary key (username, mailbox)
);
CREATE TRIGGER mergeexpires BEFORE INSERT ON expires FOR EACH ROW
BEGIN
UPDATE expires SET expire_stamp=NEW.expire_stamp
WHERE username = NEW.username AND mailbox = NEW.mailbox;
SELECT raise(ignore)
WHERE (SELECT 1 FROM expires WHERE username =
NEW.username AND mailbox = N...