Hi Eric
Unfortunately, purging the email queue was something that wasn't included in the features of the Agile Platform. So there's no easy 1-Click email purge button.
However, this can be accomplished by updating the meta-information directly on the database, for the emails in question.
Using a database client tool (Microsoft SQL Server Management Studio for SQL Server RDBMS, or SQL Plus or SQL Developer for Oracle RDBMS), you can perform one of two actions:
-
Delete the emails you which to purge from the database, by deleting the corresponding rows of the ossys_email table that should exist on the OutSystems SQL Server catalog, or HubAdmin Oracle schema. You can identify the corresponding rows by searching that table for the email subjects and recipients. For instance, suppose you want to delete the emails sent to johnsmith@outsystems.com, with the subject "Daily Activity Update". Just run the query:
select * from ossys_email where to='johnsmith@outsystems.com' and subject like '%Daily Activity Update%';
These are the rows that correspond to the emails you want to delete. In order to delete all rows according to these conditions, just change the query to:
delete from ossys_email where to='johnsmith@outsystems.com' and subject like '%Daily Activity Update%';
-
You can also set the emails status so that they will remain in the system, as if they were already sent. This will not delete the emails from the system, but instead it will fool the system saying that the emails were already sent. You can do this by updating the ossys_email_status table, using a join condition to identify the emails to update. Say you want to update the status of all emails sent to johnsmith@outsystems.com, with the subject "Daily Activity Update". Just run the query:
update ossys_email_status set NEXT_RUN=NULL, IS_RUNNING_SINCE=NULL, SENT='2010-02-02 00:00:00'
where ID IN (select ID from ossys_email where to='johnsmith@outsystems.com' and subject like '%Daily Activity Update%');
This will update the status table with a non-null date, and the emails shouldn't be sent again.
Please note that performing changes manually directly on the Agile Platform's system metadata, can lead to inconsistency and data corruption problems, so be extra carefull manipulation these queries, and always perform a database backup prior to any change.
Hope this information is helpful.
Best regards
Miguel João