Receiving subscription emails from deleted filters

Platform Notice: Data Center and Cloud By Request - This article was written for the Atlassian data center platform but may also be useful for Atlassian Cloud customers. If completing instructions in this article would help you, please contact Atlassian Support and mention it.

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Symptoms

After deleting a filter from JIRA, which had subscriptions prior to deletion, users continue to receive email notifications.

Diagnosis

Run the following query and check if the filter is still in the database:

SELECT * from searchrequest where filtername = '<name_of_filter>';

(info) All queries are written for MySQL.

This query will show all the filters which have subscriptions, it will show the id and name of the filter.

SELECT fs.id, fs.filter_i_d, sr.id, sr.filtername from filtersubscription fs, searchrequest sr where sr.id=fs.filter_i_d;

Cause

If the query shows a filter with the name you indicate, this means the filter still exist in your database but not in JIRA UI, it means it hasn't been deleted successfully. 

Note: If the deleted filter did not appear in the database table 'filtersubscription', there will be no emails send out from current JIRA regarding this filter. In this case, you need to check if you have another instance running on the same database.

Resolution

Always backup your data by using the database backup tool before you do any changes to your database.

Run the following query to delete the filter

delete from filtersubscription where filter_i_d = (select id from searchrequest where filtername = '<name_of_filter>');

Restart JIRA and do a Re-index (Administration > System > Index)

Removing the entry manually from the filtersubscription table does not remove the corresponding entry from the clusteredjob table. So the entry in clusteredjob table also needs to be removed. If a subscription is deleted from UI, it deletes the entries in both the tables.

Last modified on Feb 25, 2025

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.