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
  );

I tried deleting these Legacy Views as explained, but I am wondering why a new employee who was just hired and logged in for the first time now also has Legacy Views?

Am I going to have to delete these legacy views every time I have a new user in Eramba or am I misunderstanding something?

Yes, I think there was a misunderstanding.
Legacy views were copies of custom filters created by users in the old UI.
A new user will only have the default set of views — no legacy views will be available for them.

Hm, that is weird.
We used the above code to delete legacy views. After that, it seemed that if a user had not yet logged in after the upgrade to the new Eramba UI, legacy views would be created after they logged in for the first time with the new UI.

I then asked all my existing users to log in once, and a few days later, when I ran the code above again, I saw legacy views for a user who has just started our company show up. Like this user account didn’t even exist before we upgraded to the new Eramba UI.

Anyway, I will check the output of the above code again, after the next employee starts and let you know if I see legacy views again.

Starting from release 3.26.4, you can do this directly from the user interface.
You’ll find the option under Settings > Remove Legacy Views.

Of course, any views that are pinned or used in notifications or reports will not be removed.
The modal will show you how many views are going to be deleted.

This may also help improve the system’s performance a bit.

2 Likes

I just realized that the last minor update brought all Legacy views back.

I have now removed them using: Settings > Remove Legacy Views

Check if you are really sure to remove legacy views migrated from the previous user interface. This action will remove 3250 legacy view(s). Views that are pinned or used in notifications or reports will not be deleted.

I hope they won’t be back with the next update.

Mine keep coming back! I had over a quarter of a million of them last time I ran Settings > Remove Legacy Views.
Eramba Support are looking into it :slight_smile:

1 Like

yes, we messed something up, we are aware of it we are on it for the next release
sorry guys

We’ve just published version 3.26.6, which will hopefully fix this issue.
Thanks for your patience and for reporting it.

3 Likes