Question - delete all Legacy Views

The new UI is very much appreciated and results in much better adoption among non-techy users that are part of our GRC processes. Is it possible though to delete all the legacy views that are not tied to notifications or reports? As administrator I went through all modules and deleted the legacy views only to find out that these were only deleted for my profile while still being visible to all remaining users.

Is it possible to delete them somehow for all users?

Hello,

Unfortunately, in the previous version, filters were created per user. This means that each user will have those legacy filters.
I’ll check if there’s a query you can run to remove them completely.

2 Likes

Thank you, that is very much appreciated!

I contacted you over support email.

Is there a way this can be shared for the rest of us who see the same issue?

Thanks

1 Like

This can only be done directly in the database.
Please proceed only if you are 100% sure of what you’re doing.

delete from filters 
where advanced_filter_id is not null 
  and id not in (
    select filter_id from notification_system_items 
    where filter_id is not null
  ) 
  and id not in (
    select filter_id from report_block_filter_settings 
    where filter_id is not null
  );
2 Likes

Thank you, that worked really well. I checked the affected filters and users beforehand with the following SQL query. Good to have a rough idea what you’re about to delete.

select f.name as "filter name", u.email as "user email" from filters f
join users u ON f.user_id = u.id
where f.advanced_filter_id is not null 
  and f.id not in (
    select filter_id from notification_system_items 
    where filter_id is not null
  ) 
  and f.id not in (
    select filter_id from report_block_filter_settings 
    where filter_id is not null
  );