This simple @Macro agent purges the mail.box files of dead mail more than four days old.
Code: SELECT RoutingState = "DEAD"; FIELD PostedDate := PostedDate; @If((@Date(@Today) - PostedDate) > 4; @DeleteDocument; "");
This tip passes by a lot of issues regarding working with agents and the mail.box.
It's not documented enough (e.g., you can't schedule this agent in mail.box, so 'automatically purging of dead mails' is NOT possible using this agent), and the author probably copied it from someone else without understanding what he was doing (ok, I'm just guessing here).
Anyway, this is a bad tip that needs a lot more information to make it useful for beginners.
Do you have comments on this tip? Let us know.
This tip was submitted to the SearchDomino.com tip exchange by member Michael Chase. Please let others know how useful it is via the rating scale at the end of the tip. Do you have a useful Notes/Domino tip or code to share? Submit it to our monthly tip contest and you could win a prize and a spot in our Hall of Fame.